help-bash
[Top][All Lists]
Advanced

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

Re: [Help-bash] set time


From: DJ Mills
Subject: Re: [Help-bash] set time
Date: Thu, 13 Sep 2012 14:59:02 -0400

On Thu, Sep 13, 2012 at 11:51 AM, Max <address@hidden> wrote:
> Is there any *direct* command to shift time in bash (using date or another,
> preferably not too unpopular, console binary)?
>
> Say, it's 09:00 now and the command makes it 11:30 *without* me having 
> specified
> "11:30" but only provided the command the 2h30m interval.
>
> Note that any "indirect" methods may need complicated ways to keep
> track of the milliseconds lost while running them. It even took around one
> second in some virtual machine guest systems. So I'm hoping bash etc. happen 
> to
> have the magic needed to do the job for me.
>
>

If I'm understanding the question correctly, GNU date may do what
you're asking...
date -s '2 hours 30 minutes'



reply via email to

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