Open ecarter opened 12 years ago
That's a cool idea - but what happens if I do it this way:
tasks.sh -o -a "asdasd"
Nothing gets added! That's why I wanted to switch to getopts
or whatever the bash parsing thing is called so that random-order arguments are possible: https://github.com/pkamenarsky/atea/issues/5
Glad you like Atea! :)
Agreed, this is definitely not a fully implemented solution in the current pull request.
I'll take a look at updating this to support multiple flags. The functionality seems expected and shouldn't be much trouble.
There's a lot of potential in a robust Atea shell tool.
Agreed, a good shell script would definitely aid a lot in automating things even further.
When / if Atea gets support for configurable todo file syntax,I guess it would also be possible to use the todo.txt cli shell script.
I using zsh and have this:
export TODO=~/Dropbox/Documents/todo.txt
function todo() { if [ $# -eq 0 ]; then cat $TODO; else echo "$@" >> $TODO; fi }
function todone() { sed -i -e "/$*/d" $TODO; }
I'm sure it could be fancier but this works for me.
todo # lists all current tasks
todo testing # adds testing
todone test # marks anything starting with test as done
Very minor but I've found it useful while trying out Atea as a daily todo app.
Usage:
I currently have
tasks.sh
in my PATH withtask-add
aliased totasks.sh -a
Great project!