Skip to content

Instantly share code, notes, and snippets.

@pop
Created March 20, 2018 20:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pop/82a13f52be60de81a09ac0cb5298db26 to your computer and use it in GitHub Desktop.
Save pop/82a13f52be60de81a09ac0cb5298db26 to your computer and use it in GitHub Desktop.
A script for printing out TODO files automatically.
#!/bin/sh
# Add this file to a direcotry in your $PATH
# Add the following line to your .bashrc:
# alias sd='. /path/to/sd.sh'
cat_todo() {
cat `ls {,.}{todo,TODO}* 2>/dev/null`
}
if [ $# -eq 1 ];
then
echo "cd $1"
cd $1
else
echo "cd $HOME"
cd $HOME
fi
cat_todo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment