Joplin-Tools
Joplin-Tools copied to clipboard
Various Python tools for Joplin (Hotfolder, PDF Previews, ToDo List) and AutoIt (JoplinWinBackup) for Backups under Windows.
Joplin tools
Various Python and AutoIt tools for Joplin. Python use the Joplin API for communication.
Additional python modules
Please einstall the following python modules:
pip install click
pip install requests
pip install PyMuPDF
Tools
- hotfolder.py
- add_pdf_previews.py
- todo_overview.py
- note_overview.py
- JoplinWinBackup.au3
Parameters for all tools
-tJoplin Authorisation token. Default:Ask for token and store token-uJoplin Web Clipper URL. Defaulthttp://localhost:41184
If no token is specified, the script will ask for it and then store it in the script's directory for later use when called without the -t option.
hotfolder.py
⭐ Almost all functions are available as Hotfolder plugin.
Monitor a folder an add the Files to Joplin as a Note.
Images and text (Mimetype text/plain) are inserted directly into the note, other Files are added as attachment. The files are deleted after processing.
If you want to insert additional files directly as text, define them with the --as-plain switch.
Example
python hotfolder.py -d "Import" -p "C:\JoplinImport"
Parameters
-dSpecify the notebook in which to place newly created notes. Default:Import-pFolder for monitoring--as-plainSpecify file extensions comma separated for input as text. Example:.md, .json--tagSpecify of comma separated Tags which should be added to the note. Example:scan, todo--previewCreate a preview of the first site from an PDF file.
add_pdf_previews.py
Search for notes with a PDF attachment an create a preview of the first PDF Site and add this Preview to Note.
Parameters
-nDefines the notebook in which notes with PDF file should be searched. Default:All notebooks
Example
python add_pdf_previews.py -n "Import"
todo_overview.py
⭐ The same functionality is now available as Note overview plugin.
Creates or Updates a note with a list of all open ToDo's. All to-dos that have been exceeded are marked with a ❗.
Parameters
-nDefines the notebook in which the new Note should be created.--titleDefines the title for the note to be updated or createt. DefaultToDo overview--as-todoCreate the note as a ToDo--tagSpecify of comma separated Tags which should be added to the note. Example:scan, todo
Example
python todo_overview.py --title "Open ToDo's" --as-todo --tag "importend"
note_overview.py
⭐ The same functionality is now available as Note overview plugin.
Creates or updates a note with a list of all notes that match the search query.
Parameters
-nDefines the notebook in which the new Note should be created.--titleDefines the title for the note to be updated or createt. DefaultNote overview--tagSpecify of comma separated Tags which should be added to the note. Example:project, overview--querySpecify the seach query for the Notes like in Joplin--order_bySpecify the field for the sorting of the Table content. (All Joplin fields can be used for sorting). Defaultuser_updated_time--order_dirSorting sequence, possible valuesDESCorASC. DefaultDESC
Example
python note_overview.py --query "tag:! tag:\"project xyz\"" -n Scans --title "Overview Important Notes" --tag "!"
JoplinWinBackup.au3
⭐ There is now a backup plugin available! Simple Backup plugin.
Since there is no possibility for an automatic backup under windows, the required key combinations are sent to joplin via autoit to create a backup.
Rename the JoplinWinBackup.ini.example to JoplinWinBackup.ini and place it in the same folder es the JoplinWinBackup.au3 or JoplinWinBackup.exe.
The latest JoplinWinBackup.exe can be downloaded from the latest release.
Options from the JoplinWinBackup.ini
JoplinWinBackupDefines the Path to Joplin exe. DefaultC:\Program Files\Joplin\Joplin.exebackup_folderPath to store the Backups. DefaultC:\Backupkey_comboKey combo to get to the "JEX - Joplin export File" menue. Defaultfejsave_dialogDialog Title of the save/eport dialog. DefaultSpeichern unterask_for_startAsk if backup should be started. Default1,0= No,1= Yesbackup_file_add_dateAppend date to the Backupfile. Default1,0= No,1= Yesbackup_file_add_timeAppend time to the Backupfile. Default1,0= No,1= Yesbackup_file_nameFilename of the Backup. Defaultjoplin_backup.jexoverwrite_fileOverwrite existing backup file. Default0,0= No,1= Yes
Changelog
2020-12-26 v1.5.1
- Fix two outputs on the console
2020-12-26 v1.5.0
- Added note_overview.py script
add_pdf_previews.py
- Keep original updated time when adding PDF preview
JoplinWinBackup
- Read complet key_combo from ini
- Read sleep value wait_overwrite_dialog from ini
2020-11-18 v1.4.0
❗ breaking changes, requires at least Joplin v1.4.11 ❗
- Change to new Joplin API