What's todo.sh?
todo.sh is a powerful shell script that adds to, edits, sorts and searches your todo.txt file from the command line. Mark items as complete and archive them into a done.txt file with todo.sh as well.
todo.sh Screencast
See todo.sh in action here:
Note: In the setup shown, I've aliased todo.sh to t to reduce typing.
Download todo.sh
Download the full todo.sh package. (Or, just get todo.sh or view the browser-friendly todo.sh) See the CHANGELOG for what's new.
Installation
- Unzip todo.zip. Using the text editor of your choice, edit the section of the .todo file that reads:
# Your todo.txt directory TODO_DIR="/Users/gina/Documents/todo"
Replace "/Users/gina/Documents/todo" to wherever your todo.txt lives.
Mac users, here's help viewing/editing files and folders that start with a dot.
- Make the todo.sh script exectuable:
$ chmod +x todo.sh
- Move the .todo configuration file to your home directory:
mv .todo ~/.
- Backup your todo.txt before using todo.sh. Type
./todo.shto see the usage message.
Alternate Versions
- todo.py
A Python version of todo.sh authored by Shane Koster.
Tips and tricks
- Access todo.sh from anywhere in the file tree. Add the following to your ~/.bashrc file (~/.bash_profile for Mac users, ~/.profile for Cygwin users):
PATH=$PATH:"/path/to/your/todo/scripts"
- Avoid typing todo.sh every time. Add the following to your ~/.bashrc file (~/.bash_profile for Mac users, ~/.profile for Cygwin users):
alias t='todo.sh -d /path/to/your/.todo'
Then you simply typet add laundryfrom anywhere in your file tree to add a task. - Windows SlickRun integration. Set up a SlickRun keyword to execute todo.sh commands without being in a Cygwin window.
MagicWord: td Filename/URL: cmd.exe Parameters: /c bash --login -i -c "todo.sh $i$"
- Display your todo list on your desktop. Windows users, Samurize gets the job done. Mac users will want GeekTool.
- IM your todo.txt. Use the todobot.pl to instant message your todo.sh commands from any AIM client.
- Access your remote server's todo.txt via ssh. If you have a shell account on remote.server.com, alias your todo.sh commands to do the same thing as usual but prepend "ssh username@remote.server.com" to them. Something like:
ssh username@remote.server.com todo.sh list
Which displays the remote todo list. - Set up a tickler system to work with todo.txt. Mailing list member Tannie wrote an tickler.sh script which moves items you have to do in the future to todo.txt.
- Integrate todo.txt with a calendar using the Unix program remind.
- Get your todo's via email using postfix.
Platform compatibility
Todo.sh has been tested on:
- Cygwin for Windows
- Mac OS X 10.4 Terminal
- Ubuntu 5.10 / Sed 4.1.4 / Grep 2.5.1 / Cat 5.2.1 / wc 5.2.1
Let us know if you're using todo.sh successfully anywhere else.
Developers
If you're interested modifying or enhancing todo.sh, join the mailing list to discuss or code one of the future development proposals.
A set of (admittedly incomplete and primitive) todo.sh tests are available for testing todo.sh modifications.
Known bugs
- Apostrophe's not enclosed in quotes break with the add/append/replace command. That is,
todo.sh add "fix lily's bike"works, buttodo.sh add fix lily's bikedoes not.
Author
Unless otherwise noted, all the todo.txt scripts published herein are authored by Gina Trapani and licensed under the GNU General Public License.
Scripts and text originally published as an ongoing Todo.txt series at Lifehacker.com. Special thanks to all the Lifehacker readers who contributed to Todo.sh by fixing code, adding features, reporting bugs and making suggestions.
All software comes as is with no warranty. Do back up your todo.txt before you read another word. Questions, support and help is available in the Todo.txt Mailing list.
