Restart command
This commit is contained in:
@@ -38,6 +38,7 @@ impl Engine {
|
||||
("preset list", "List available presets"),
|
||||
("preset use <name>", "Switch active preset"),
|
||||
("strategy start", "Start strategy runtime"),
|
||||
("strategy restart", "Restart strategy runtime"),
|
||||
("strategy set <id>", "Change active strategy"),
|
||||
("strategy <command>", "Send command to strategy runtime"),
|
||||
];
|
||||
@@ -236,6 +237,12 @@ impl Engine {
|
||||
match strategy_command {
|
||||
"start" => {}
|
||||
|
||||
"restart" => {
|
||||
self.strategy_engine
|
||||
.reload(&self.config.lock().await.get_ref()?.strategy)
|
||||
.await?;
|
||||
}
|
||||
|
||||
"set" => {
|
||||
set_cfg!(id);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user