mirror of https://github.com/jackwener/wx-cli.git
fix(daemon): pass global --tcp to daemon start
DaemonCommands::Start had its own --tcp subcommand flag, so 'wx --tcp=ADDR daemon start' ignored the global --tcp and started the daemon with no TCP listener. Now the global --tcp is used as fallback when the subcommand flag is absent.pull/43/head
parent
cba33e4630
commit
1be706ddb0
|
|
@ -8,7 +8,7 @@ pub fn cmd_daemon(cmd: DaemonCommands, tcp_addr: Option<&str>) -> Result<()> {
|
|||
DaemonCommands::Status => cmd_status(tcp_addr),
|
||||
DaemonCommands::Stop => cmd_stop(tcp_addr),
|
||||
DaemonCommands::Logs { follow, lines } => cmd_logs(follow, lines),
|
||||
DaemonCommands::Start { tcp } => crate::daemon::run_start(tcp),
|
||||
DaemonCommands::Start { tcp } => crate::daemon::run_start(tcp.or_else(|| tcp_addr.map(String::from))),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue