aboutsummaryrefslogblamecommitdiffstats
path: root/lem
blob: dd1cf00a5b669e8e689fdbb7307ed7c6cced9666 (plain) (tree)
1
2
3
4
5
6
               

                       
                         
                
 









                            
                             
                                   
 
                                  

              
#!/usr/bin/bash

NOTES=/home/$USER/Notes
TARGET_DIR=$NOTES/homezet
VIM=/usr/bin/vim

if [[ "$1" = "-m" ]]; then
    msg="${*:2}"
    TARGET_DIR=$NOTES/modzet
    shift
else
    msg="$@"
    shift
fi


STAMP="$(date +%G%m%d%H%M%S)"
F_PATH="$TARGET_DIR/$STAMP-$msg.md"

printf "# %s", "$msg" >> "$F_PATH"

$VIM "$F_PATH"