Hi,

lilit-aibolit wrote on Fri, Apr 18, 2014 at 03:24:36PM +0300:

> $ date --date="last month" +%b
> Mar

Time for a little shell golfing?

Look, i'll play it nice and even add two blanks for readability.

$ date -j +%b $(printf "%02d010000" $(( ($(date +%m)+11)%12 )))
Mar

There is no need to install GNU tools for simple one-liners.

Yours,
  Ingo

Reply via email to