Skip to content

Repeat a command at a given interval, and aggregate its output

License

Notifications You must be signed in to change notification settings

Tabcorp/cli-interval

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

interval

Repeat a command at a given interval, and aggregate its output.

NPM License Dependencies

npm install -g cli-interval

The following example outputs a random number to stdout every second.

interval -t 1s "echo \$RANDOM"

It will aggregates both stdout and stderr over time, and pipes them into its respective outputs.

Arguments

  • --help print the command usage
  • -t specify the interval at which to run the command, e.g.
    • -t 0.5 every 500 milliseconds
    • -t 10 every 10 seconds
    • -t 5s every 5 seconds
    • -t 2m every 2 minutes
    • -t 1h every hour

About

Repeat a command at a given interval, and aggregate its output

Resources

License

Stars

Watchers

Forks

Packages

No packages published