vimwiki/backup.sh

13 lines
365 B
Bash
Executable File

#!/bin/bash
# Get dir of the vimiwki
SCRIPT_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
#add changes to github
git -C "$SCRIPT_DIR" add .
git -C "$SCRIPT_DIR" commit -m "Update for $(date "+%d-%m-%y %R")"
git -C "$SCRIPT_DIR" push
#let me know about it
notify-send "Vimwiki" "Your Vimwiki has been backed up!" --expire-time=5000