Created
May 9, 2013 08:04
-
-
Save jarvist/5546170 to your computer and use it in GitHub Desktop.
A few lines that have sat at the end of my .bashrc for the last few years.
Originally this warned me when my PhD was ending + the date I needed to submit my thesis, and as I passed into PostDoc purgatory, I use it to remind me how long I have till the end of the next contract. As a bonus, it works correctly once you've passed the deadline, infor…
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
theend=` date --date "30 December 2013 17:00" +%s ` | |
now=` date +%s ` | |
diff=` expr $theend - $now ` | |
echo "Really Unemployed in: " `expr $diff / 86400` days `expr \( $diff % 86400 \) / 3600` hours `expr \( \( $diff % 86400 \) % 3600 \) / 60` minutes `expr $diff % 60` seconds. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment