Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Bash script. Prints how much is left until a specified time.

branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

README.md

countdown-status

countdown-status is a bash script that prints how much is left until a specified time.

Usage

In console, one can simply set a period (with -h for hours, -m for minutes, -s for seconds):

  > countdown-status -m 30

and then every time the script is called, it prints how much time is left:

  > countdown-status
  29:53

and after the time is up:

  > countdown-status
  Time's up!

Customization

  • prefix message:
  > countdown-status -b "Time left: " -m 30
  Time left: 30:00
  • suffix message:
  > countdown-status -a " left." -m 30
  30:00 left.
  • time's up message:
  > countdown-status -u "Time is up, relax :-)" -m 30
  # ... and after 30 minutes:
  > countdown-status
  Time is up, relax :-)

Data file

The app needs to save data to the disk in order to make it available for subsequent runs. By default, it uses ~/.countdown-status-data file.

Custom data file can be used with -f option (it must be present for every app run):

  > countdown-status -f ~/.custom-countdown-status-data -m 30
  # then
  > countdown-status -f ~/.custom-countdown-status-data
  29:55

Note: Using separate data files is necessary when one wants to run more than one timer simultaneously.

Installation

The application is just one file: https://raw.github.com/jacekmikrut/countdown-status/master/countdown-status

One needs to read the license, download the file and make sure it is executable.

Practical application

countdown-status can be used by applications that periodically display/refresh information, for example i3status.

Feedback

Feature requests and bug reports as well as ideas/suggestions of how to improve the app's code/structure are welcome!

Author

Jacek Mikrut

License

License is included in the LICENSE file.

Something went wrong with that request. Please try again.