3 ms·
Often I use cal to find the previous or next month. I never understood why two parameters it assumes `cal mm yyyy` but when one parameter is provided assumes `
by adamrmcd 4y ago
Often I use cal to find the previous or next month. I never understood why two parameters it assumes `cal mm yyyy` but when one parameter is provided assumes `cal yyyy` instead of `cal mm`.
ie, I just want to see April of this year: but `cal 4` returns Jan-Dec 0004 CE <!>
`cal -3` is perfect!
- lapsis_beeftech 4y agoYour cal likely also recognizes month names, try "cal apr" for April of this year.
- mandelbrotwurst 4y agoMine does not ~ $ cal apr cal: year `apr' not in range 1..9999
- lapsis_beeftech 4y agoWhich cal? It is a relatively simple program that has seen many implementations and extensions. The cal I had in mind was the version from the util-linux package, it is commonly found in Linux distributions and supports full or abbreviated month names as arguments.
- mandelbrotwurst 4y agoGotcha. This is the one pre-installed on MacOS 11.6.
- irishsultan 4y ago`cal -m 4` should work for that as well.