mirror of
https://github.com/tauri-apps/tauri.git
synced 2024-11-27 15:13:23 +03:00
fix(cli): do not prompt for device when --open
is provided
This commit is contained in:
parent
1af9be904a
commit
8835633955
@ -99,11 +99,15 @@ fn run_dev(
|
||||
) -> Result<()> {
|
||||
setup_dev_config(&mut options.config)?;
|
||||
let env = env()?;
|
||||
let device = match device_prompt(&env, options.device.as_deref()) {
|
||||
Ok(d) => Some(d),
|
||||
Err(e) => {
|
||||
log::error!("{e}");
|
||||
None
|
||||
let device = if options.open {
|
||||
None
|
||||
} else {
|
||||
match device_prompt(&env, options.device.as_deref()) {
|
||||
Ok(d) => Some(d),
|
||||
Err(e) => {
|
||||
log::error!("{e}");
|
||||
None
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -113,11 +113,15 @@ fn run_dev(
|
||||
) -> Result<()> {
|
||||
setup_dev_config(&mut options.config)?;
|
||||
let env = env()?;
|
||||
let device = match device_prompt(&env, options.device.as_deref()) {
|
||||
Ok(d) => Some(d),
|
||||
Err(e) => {
|
||||
log::error!("{e}");
|
||||
None
|
||||
let device = if options.open {
|
||||
None
|
||||
} else {
|
||||
match device_prompt(&env, options.device.as_deref()) {
|
||||
Ok(d) => Some(d),
|
||||
Err(e) => {
|
||||
log::error!("{e}");
|
||||
None
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user