# cf. http://www.macgeekery.com/tips/cli/a_neat_bash_one-liner function month() { #/usr/bin/cal | sed -E -e 's/^/ /' -e 's/$/ /' -e "s/ $(/bin/date +%e) /$(printf '\e[1m&\e[m')/" #/usr/bin/cal | sed -E -e 's/^/ /' -e 's/$/ /' -e "s/ $(/bin/date +%e) /$(printf '\e[1;31m&\e[m')/" #/usr/bin/cal | sed -E -e 's/^/ /' -e 's/$/ /' -e "s/ $(/bin/date +%e) /$(printf '\e[1;32m&\e[m')/" #/usr/bin/cal | sed -E -e 's/^/ /' -e 's/$/ /' -e "s/ $(/bin/date +%e) /$(printf '\e[1;33m&\e[m')/" #/usr/bin/cal | sed -E -e 's/^/ /' -e 's/$/ /' -e "s/ $(/bin/date +%e) /$(printf '\e[1;34m&\e[m')/" #/usr/bin/cal | sed -E -e 's/^/ /' -e 's/$/ /' -e "s/ $(/bin/date +%e) /$(printf '\e[1;35m&\e[m')/" /usr/bin/cal | sed -E -e 's/^/ /' -e 's/$/ /' -e "s/ $(/bin/date +%e) /$(printf '\e[1;36m&\e[m')/" return 0 } month alias day=month day
Never been to CodeSnippets before?
Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world (or not, you can keep them private!)
month & day (See related posts)
You need to create an account or log in to post comments to this site.
Related Posts
» cwd - copy with date in date shell osx mac bash unix file copy
» fsinfo in date shell osx mac apple bash unix file create utility tool system info
» Limit Google searches by date in date shell osx mac google search bash unix web internet
» ws - web search from the com... in shell osx mac search bash unix commandline web
» snippet in shell osx mac html bash unix commandline web download convert textutil ed snippet
» Switching firewall settings ... in shell osx mac bash unix ipfw firewall ruleset switch
Snippets (source code soon to be available) developed by Peter Cooper and powered by Ruby On Rails