Unidata / UDUNITS-2

API and utility for arithmetic manipulation of units of physical quantities
http://www.unidata.ucar.edu/software/udunits
Other
62 stars 36 forks source link

Have udunits2(1) return timestamp in definition #37

Open semmerson opened 9 years ago

semmerson commented 9 years ago

David Robertson robertson@marine.rutgers.edu via unidata.ucar.edu

to udunits Hi,

With UDUNITS I can type something like "256996800 seconds since 2006-01-01 00:00:00" in the "You have:" and then just leave "You want:" blank and it will give me:

Definition: "256996800 seconds since 2006-01-01 00:00:00.0000 UTC"
"256996800 seconds since 2006-01-01 00:00:00" is 2014-02-22 12:00:0 UTC

However, with UDUNITS2 it just replies "256996800 s" which is pretty useless in my situation. I am interested in the "is 2014-02-22 12:00:0 UTC" portion of the answer. Is there a way to get UDUNITS2 to behave in the old way? Preferably using the -H and -W flags.

Thanks, Dave

rjdave commented 6 years ago

Hi,

Any chance this will be added any time soon. As we move to more and more scripting to generate, process, and prepare input and forcing files for daily forecast model runs this capability would be increasingly useful.

Thanks, David Robertson (robertson@marine.rutgers.edu)