I want to synchronize all the PDFs from one directory (my Zotero library) to Dropbox. Finally, I want to have a list of all the PDFs, not the directory names.
I successfully synchronized all my PDFs with the following command:
rsync -az --include="*/" --include="*.pdf" --exclude="*" \ --prune-empty-dirs /zotero /dropbox
I think I can easily set up a
cron job to redo that task every day, but haven't tried that yet.
But now my folder on Dropbox still has all the directories with the PDFs in it (e.g.
6NVTACJH > xyz.pdf)
I would love to only have all the pdfs listed in one directory. Following an advice from the web, I tried to
find all pdfs and create a hardlink.
But this command does not work yet.
ln $( find -name="*.pdf" -type f - links 1 ) /dropbox
Can you please help me with that last command?