From bae338ad0babbea3e015d4a1bcf555fcfc20e0cb Mon Sep 17 00:00:00 2001 From: Gavin D'souza Date: Fri, 12 Nov 2021 18:15:51 +0530 Subject: [PATCH] feat(minor): Any procman in bench start Using the `-m` flag, we can use any process manager instead of the standard honcho. For instance, you've installed overmind on your machine and are married to it, just run `bench start -m overmind` :P --- bench/commands/utils.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bench/commands/utils.py b/bench/commands/utils.py index 0b2b002f..5ab0e3d9 100644 --- a/bench/commands/utils.py +++ b/bench/commands/utils.py @@ -11,9 +11,10 @@ import click @click.option('--no-prefix', is_flag=True, default=False, help="Hide process name from bench start log") @click.option('--concurrency', '-c', type=str) @click.option('--procfile', '-p', type=str) -def start(no_dev, concurrency, procfile, no_prefix): - from bench.utils import start - start(no_dev=no_dev, concurrency=concurrency, procfile=procfile, no_prefix=no_prefix) +@click.option('--man', '-m', help="Process Manager of your choice ;)") +def start(no_dev, concurrency, procfile, no_prefix, man): + from bench.utils.system import start + start(no_dev=no_dev, concurrency=concurrency, procfile=procfile, no_prefix=no_prefix, procman=man) @click.command('restart', help="Restart supervisor processes or systemd units")