Skip to content

Instantly share code, notes, and snippets.

@munho
Created March 5, 2015 23:50
Show Gist options
  • Save munho/fc2d469e5b7e1357e4a0 to your computer and use it in GitHub Desktop.
Save munho/fc2d469e5b7e1357e4a0 to your computer and use it in GitHub Desktop.
build timestamp log
export BUILD_NUMBER=${USER}-`date +%Y%m%d-%H%M%S`
$ echo "hello" | tee logfile_$(date '+%Y%m%d-%H%M%S').txt
hello
$ ls logfile_*
logfile_20130821-101235.txt
$ date '+%Y%m%d-%H%M%S'
20140302-091211
progname 2>&1 | tee tempfile ; textmate tempfile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment