Fun Tips

From JoeHacker

At least these are fun tips for me.

Fun with epoch dates

Unix does a great job of storing time as a long integer value. They call this time Epoch and it marks the seconds in time from January 1, 1970 at midnight. I see these times in various logs and have wrote programs to convert them. There is an easy way to do this at the command prompt. Just us the '@' sign in front of the value.

date -d @1234567890

To use date to dump the epoch time:

date +%s