0

Actually I expect the output like

from current timestamp to 10s+current timestamp

ex:

11:49:01
11:49:02
11:49:03
.....
11:49:10

But this output must be coming in banner output.

Hint: I am able to get the first set of sequence using the below script:

while [ 1 ]; do
    echo $(date +%H:"$(( `date +%M`+1))":%S)
    sleep 1
done

I want to know how to get the above script output using banner?

3
  • the time sequence is working perfectly, but I wanna concate the output with banner command?
    – user194644
    Oct 24, 2016 at 6:38
  • can you pls tell me what is wrong with this script?
    – user194644
    Oct 24, 2016 at 7:08
  • $ repeat 1000 sh -c '( clear ; date +" %H.%M.%S" | xargs banner ; sleep 1)'
    – user194644
    Oct 24, 2016 at 7:08

1 Answer 1

1
  • just use date -d+10s to get 10 seconds ahead. (by the way, you mention 10 seconds in question and use +1 minute in your code)

  • next use banner or printerbanner

    ...
    banner $(date -d '+10 seconds' '+%T') # if banner exist, or
    printbanner $(date -d '+10 seconds' '+%T') # ubuntu
    ...
    

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .