Skip to content

Instantly share code, notes, and snippets.

@dwaxe
Created February 24, 2017 11:24
Show Gist options
  • Save dwaxe/5c1af03a52b2747bed48e1d1b48fd12e to your computer and use it in GitHub Desktop.
Save dwaxe/5c1af03a52b2747bed48e1d1b48fd12e to your computer and use it in GitHub Desktop.
fish function to create today's diary entry
function today
set todaystr (date "+%B%d.txt")
if test -e $todaystr
vim +3 $todaystr
else
date "+%B %d, %Y" >$todaystr
echo \n\n >>$todaystr
vim -c 'startinsert' +3 $todaystr
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment