Re: date: new options to parse input date with strptime(3)

2019-08-01 Thread Stephane Chazelas
2019-08-01 03:24:29 -0600, Assaf Gordon: [...] > > > I like this, and think it's useful functionality. > > > It's equivalent to -f in date(1) on FreeBSD, > > > so we should probably support that short option > > [...] > > > > Note that busybox date has -D for that. > > In gnu date(1), -f is

Re: date: new options to parse input date with strptime(3)

2019-08-01 Thread Assaf Gordon
Hello, Thank you for the review. (replying to both emails together) On Wed, Jul 31, 2019 at 04:27:20PM +0100, Stephane Chazelas wrote: > 2019-07-31 14:59:42 +0100, Pádraig Brady: > > On 26/07/19 08:29, Assaf Gordon wrote: > [...] > > > The first patch adds '--date-format=FORMAT', where FORMAT is

Re: date: new options to parse input date with strptime(3)

2019-07-31 Thread Stephane Chazelas
2019-07-31 14:59:42 +0100, Pádraig Brady: > On 26/07/19 08:29, Assaf Gordon wrote: [...] > > Some time ago there was a discussion relating to diffuculties of using > > GNU date's parsing. There was a mention of how using strptime(3) makes > > parsing explicit and easy. > > > > I like that idea,

date: new options to parse input date with strptime(3)

2019-07-26 Thread Assaf Gordon
Hello, Some time ago there was a discussion relating to diffuculties of using GNU date's parsing. There was a mention of how using strptime(3) makes parsing explicit and easy. I like that idea, and decided to try my hand at adding such options. Attached is a proof of concept. The first patch