mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-09 20:29:10 +02:00
[yabridgectl] Add an option to undo setting --path
This commit is contained in:
@@ -137,6 +137,7 @@ pub fn show_status(config: &Config) -> Result<()> {
|
||||
pub struct SetOptions<'a> {
|
||||
pub method: Option<&'a str>,
|
||||
pub path: Option<PathBuf>,
|
||||
pub path_auto: bool,
|
||||
}
|
||||
|
||||
/// Change configuration settings. The actual options are defined in the clap [app](clap::App).
|
||||
@@ -152,6 +153,10 @@ pub fn set_settings(config: &mut Config, options: &SetOptions) -> Result<()> {
|
||||
config.yabridge_home = Some(path.clone());
|
||||
}
|
||||
|
||||
if options.path_auto {
|
||||
config.yabridge_home = None;
|
||||
}
|
||||
|
||||
config.write()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user