tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Weekday abbreviations in output of cal(1)



Am 30.06.20 um 10:59 schrieb Martin Husemann:
> On Tue, Jun 30, 2020 at 10:53:38AM +0200, Michael Siegel wrote:
>> Also, to the best of my knowledge, parsing the output of cal(1) is about
>> the only method to get certain calendar information in Unix shell
>> scripts.
> 
> Now that makes me curious - can you give an example?
> 
> I think almost always "date +format" is a lot easier, and at quick thought
> there was no information I could think of that cal(1) gives that would not
> be available that way (plus maybe some shell arithmetic expressions).

Well, how would you use date(1) to return the number of days in any
given month, for example?


Michael


Home | Main Index | Thread Index | Old Index