daniel@barcelona:~$ cat blog/bash-commands.md
← back to blogBash Tips: Calendar & Date
I just learned about this tiny utility within Bash. It's nothing special, but just loved how easy and how clean it was.
Within a terminal window, executing the cal command will provide you with a calendar. The following is an example:
> cal
December 2019
Su Mo Tu We Th Fr Sa
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30 31
Also within a terminal window, executing the date command will provide you with a formatted datetime string.
> date
Mon Dec 2 14:06:58 CET 2019