Skip to content

Instantly share code, notes, and snippets.

@lee2sman
Last active October 30, 2020 20:00
Show Gist options
  • Save lee2sman/0d3865bfa96ac9726acb255b64bab776 to your computer and use it in GitHub Desktop.
Save lee2sman/0d3865bfa96ac9726acb255b64bab776 to your computer and use it in GitHub Desktop.
fish script for writing 750words (approx 3 pages) a day
#!/usr/bin/env fish
# note: all progress saved whether you hit 750 words or not
# replace with location of journal
set journal ~/.journal.txt
# start
echo "today's 750 words..."
set totalcount 0
echo (date +"%b %d, %Y") >> $journal
echo "--------------" >> $journal
while test $totalcount -lt 750
read entry
set thiscount (echo $entry | wc -w)
set totalcount (math $thiscount + $totalcount )
echo "Total words: $totalcount"
echo $entry >> $journal
echo "" >> $journal
end
echo "" >> $journal
echo "Complete!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment