Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a task using bash script #19

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

ecarter
Copy link

@ecarter ecarter commented Feb 22, 2012

Very minor but I've found it useful while trying out Atea as a daily todo app.

Usage:

tasks.sh -a "[github] Contribute to Atea project - 5m"

I currently have tasks.sh in my PATH with task-add aliased to tasks.sh -a

Great project!

Usage: tasks.sh -a "[github] Contribute to Atea project - 5m"
@pkamenarsky
Copy link
Owner

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: #5

Glad you like Atea! :)

@ecarter
Copy link
Author

ecarter commented Feb 22, 2012

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.

@pkamenarsky
Copy link
Owner

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.

@databyte
Copy link

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants