paper-qa icon indicating copy to clipboard operation
paper-qa copied to clipboard

copy from Zotero storage

Open g-simmons opened this issue 2 years ago • 2 comments

Copy files from Zotero storage instead of downloading, if possible. Discussed in #66.

Changes

  • import shutil for file copy
  • add zotero_storage arg to ZoteroDB init to specify the Zotero storage location, default is "~/Zotero/storage/"
  • if pdf for a document doesn't exist yet, first check Zotero storage.
  • if one pdf exists in Zotero storage, copy it to the paperqa storage location and return the destination path
  • if there is an error attempting to copy the pdf, fall back to downloading
  • if zero or more than one pdfs exist, fall back to downloading

g-simmons avatar Apr 24 '23 00:04 g-simmons

Hi @g-simmons thank you for this PR. We just released v5 today which changes basically the whole repo.

If you are still interested, please rebase this PR atop the current main branch.

jamesbraza avatar Sep 11 '24 17:09 jamesbraza

@jamesbraza thanks for the info. I probably won't be able to rebase this any time soon (other time commitments) :/

g-simmons avatar Sep 11 '24 18:09 g-simmons