bug-coreutils
[Top][All Lists]
Advanced

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

bug#52525: wanted to add option to date command to handle pure numeric i


From: Mike Marchywka
Subject: bug#52525: wanted to add option to date command to handle pure numeric input in varying ways and output for invalid dates
Date: Wed, 15 Dec 2021 20:39:04 +0000

I'm trying to implement the options shown below. I downloaded the coreutils 
source
for my distro and don't expect a problem compling and implementing it.
However, is there any interest in adding similar functions to the main code?

I would imagine something like,

date  --option=four-digits-are-YYYY,invalid-output-blank-line 

My immediate concern is getting this to take the input as a year rather than 
HHMM and
it would be easier to make date more versatile than put logic around it,

$echo 2000 | date +%Y -f-
2021

not sure if anyone else would want that.

Thanks. 



 Mike Marchywka 
306 Charles Cox Drive 
Canton, GA 30115
470-758-0799
404-788-1216 




________________________________________
From: Mike Marchywka
Sent: Wednesday, December 15, 2021 2:08 PM
To: coordinator@translationproject.org
Subject: the ubuntu "date" command info pointed me to you, question on 
modification

I wanted to add an option to the linux date command to
deal with pure number date stings - allowing for a 4 digit number
to be a year instead of HHMM - which should be easy
for me to do but I wanted to see how it integrates.
Also, I wanted an output option, that I could write, to
send an invalid message to stdout instead of stderr.

How should I proceed?

Thanks.


 Mike Marchywka
306 Charles Cox Drive
Canton, GA 30115
470-758-0799
404-788-1216







reply via email to

[Prev in Thread] Current Thread [Next in Thread]