mirror of
https://github.com/brunofontes/linuxShortcuts.git
synced 2024-11-24 05:24:56 +00:00
16 lines
337 B
Bash
16 lines
337 B
Bash
|
#!/bin/bash
|
||
|
|
||
|
BACKUP_DIR="/home/bruno/Backups/Joplin"
|
||
|
JOPLIN_BIN="/bin/joplin"
|
||
|
|
||
|
$JOPLIN_BIN sync
|
||
|
$JOPLIN_BIN e2ee decrypt
|
||
|
|
||
|
# Delete old backups
|
||
|
cd "$BACKUP_DIR"
|
||
|
rm -r "./joplin.jex"
|
||
|
rm -rf "./MD"
|
||
|
|
||
|
$JOPLIN_BIN --log-level debug export --format jex "$BACKUP_DIR/joplin.jex"
|
||
|
$JOPLIN_BIN --log-level debug export --format md "$BACKUP_DIR/MD"
|