Keeps your processes running.
Go to file
Ian Wijma ef1e2c56c0 Refactor 'Retry' instance creation and modify 'run_command' function
Changed the approach for creating 'Retry' instance in main() to avoid mutation behavior by setting 'max_retries', 'timespan' and 'restart_name' initially. The 'per_minute' and 'per_hour' arguments now directly modify these values. Additionally, the 'run_command' function and related functions were refactored to pass 'Retry' instance by value, not reference and to handle 'retry' history separately for each command execution. These changes were made to improve code readability and maintainability.
2023-12-02 21:52:09 +11:00
.github/workflows Update workflow run-name and remove id from 'Compile and release' 2023-11-21 01:13:08 +11:00
assets Add readme.md file 2023-11-23 21:27:15 +11:00
bin Improve script safety by quoting variables and updating comparisons 2023-11-20 23:40:56 +11:00
src Refactor 'Retry' instance creation and modify 'run_command' function 2023-12-02 21:52:09 +11:00
.gitignore Updated .gitignore, Cargo.toml and release.yaml files 2023-11-21 00:57:18 +11:00
Cargo.lock Update version and fix CI action name 2023-11-21 01:03:51 +11:00
Cargo.toml Update version and fix CI action name 2023-11-21 01:03:51 +11:00
readme.md Add readme.md file 2023-11-23 21:27:15 +11:00

readme.md

Keep Running

Keep running is a quick and easy way to keep a process running during development or other non-production tasks.

Please for the love of sanity, do not use this is production...

Usage

Below you will see the output of the --help command. Do note that if you don't specify any --per-* flag, it defaults to --per-minute=4.

Usage: kr [OPTIONS] <COMMAND>

Arguments:
  <COMMAND>  

Options:
      --per-minute <PER_MINUTE>  [default: 0]
      --per-hour <PER_HOUR>      [default: 0]
      --delay <DELAY>            [default: 0]
  -h, --help                     Print help
  -V, --version                  Print version

Use cases

Game servers

/keep-running/ is a great tool to run, for example, a Modded minecraft server. As it automatically restarts the server if a crash occurs.

img.png