keep-running

Keep a script or bash cmd running. Relaunch the command or script when exit.


Keywords
keep, running
License
MIT
Install
pip install keep-running==1.0.0

Documentation

keep running

Kepp a script or bash cmd running. Relaunch the command or script when exit.

https://pypi.python.org/pypi/keep-running

installation

pip install keep-running

usage

For example: test-program.sh

#!/bin/bash
for i in {1..10}
do
    echo `date` ':' $i
    sleep 1
done

Keep it running:

$ keep-running test-program.sh

files

  • log file

    The log file will be: test-program.sh.log in the same directory with test-program.sh.

  • lock file

    The file used to lock is test-program.sh.lock.

Enjoy coding!