[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [HTCondor-users] convert from 'date +"%H-%M %m-%d-%Y"' to seconds from 1970
- Date: Tue, 05 May 2020 11:29:53 +0200
- From: Arne Babenhauserheide <arne_bab@xxxxxx>
- Subject: Re: [HTCondor-users] convert from 'date +"%H-%M %m-%d-%Y"' to seconds from 1970
Beyer, Christoph <christoph.beyer@xxxxxxx> writes:
> maybe a stupid question, is there a way to translate a `date +"%H-%M %m-%d-%Y"` (or similar) into a HTC usable 'seconds-since-1970' maybe using time() or formatTime() inside a classadd string ?
> I know formatTime() works the other way round but I would like to do some START calculation based on a date given by the user which would be more conveniant to be in 'human readable' format ...
Hereâs a long form:
guile -c '(import (srfi srfi-19))(display (date->string (string->date "18-06 05-24-1983" "~H-~M ~m-~d-~Y") "~s\n"))'
Iâm sure thereâs a shorter shell-command, but I donât have it at hand
heiÃt politisch sein
ohne es zu merken