.local/bin: Add focus & notes/writing scripts

This commit is contained in:
xerus2000 2020-06-26 23:21:22 +02:00
parent 4e5a4e574a
commit df4a2aa87f
2 changed files with 19 additions and 0 deletions

4
.local/bin/focus Executable file
View File

@ -0,0 +1,4 @@
#!/bin/sh
playlistPath="$HOME/daten/music/Playlists"
vlc $(find $playlistPath -iname "Focus$1.m3u8" | grep . || find $playlistPath -iname "$1.m3u8") >/dev/null 2>&1 &

15
.local/bin/wr Executable file
View File

@ -0,0 +1,15 @@
#!/bin/sh
p=$PWD
cd $HOME/daten/Dropbox/dokumente/notes
case $1 in
log) file=life/${2:-general};;
idea) file=idea/$2.md;;
write) file=writings/$2.md;;
*) file=$2.md;;
esac
comment=$(test -d $file && echo Edit || echo Create)
test "$3" && echo $3 >>$file || $EDITOR $file
git add $file
git commit -m "$comment $file"
git push
cd $p