Skip to content

Instantly share code, notes, and snippets.

@ttscoff
Created July 26, 2014 22:33
Show Gist options
  • Save ttscoff/46905fad65a4450a7a18 to your computer and use it in GitHub Desktop.
Save ttscoff/46905fad65a4450a7a18 to your computer and use it in GitHub Desktop.
Bash function for creating and opening per-project TaskPaper files.
# [Create and] open project todo
# If you don't pass a name as an argument, it's pulled from the directory name
td() {
if [[ -n $1 ]]; then
proj=$1
todofile=$proj.taskpaper
else
proj=${PWD##*/}
todofile=$proj.taskpaper
fi
if [ ! -e $todofile ]; then
touch $todofile
echo -e "Inbox:\n$proj:\n\tBugs:\n\tNew Features:\nArchive:" >> $todofile
fi
open -b com.hogbaysoftware.TaskPaper.mac $todofile
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment