From 9f8c5acf525754eda6025abe6333de81180ba595 Mon Sep 17 00:00:00 2001 From: jesopo Date: Thu, 21 Nov 2019 10:39:26 +0000 Subject: add a way to execute commands through bitbotd (use for master-password) --- bitbotctl | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'bitbotctl') diff --git a/bitbotctl b/bitbotctl index 86790c0f..7e8425e8 100755 --- a/bitbotctl +++ b/bitbotctl @@ -24,6 +24,8 @@ SIMPLE = ["rehash", "reload", "stop"] if args.command == "log": arg_parser.add_argument("--level", "-l", help="Log level", default="INFO") +elif args.command == "command": + arg_parser.add_argument("subcommand") elif args.command in SIMPLE: pass else: @@ -53,6 +55,8 @@ _send("0 version 0") if args.command == "log": _send("1 log %s" % args.level) +elif args.command == "command": + _send("1 command %s" % args.subcommand) elif args.command in SIMPLE: _send("1 %s" % args.command) -- cgit v1.3.1-10-gc9f91