feat: feature complete install remote with category selection
This commit is contained in:
@@ -575,7 +575,7 @@ fn resolve_conflict(planned: &PlannedFile, sticky: &mut StickyMode) -> Result<Co
|
|||||||
*sticky = StickyMode::ReplaceAll;
|
*sticky = StickyMode::ReplaceAll;
|
||||||
Ok(ConflictAction::Replace)
|
Ok(ConflictAction::Replace)
|
||||||
}
|
}
|
||||||
"abort" => bail!("Aborted by user."),
|
"abort" => bail!("Install aborted by user at conflict resolution."),
|
||||||
_ => unreachable!("inquire::Select returned an unexpected option"),
|
_ => unreachable!("inquire::Select returned an unexpected option"),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+8
-8
@@ -92,6 +92,14 @@ async fn main() -> Result<()> {
|
|||||||
|
|
||||||
install_builtins()?;
|
install_builtins()?;
|
||||||
|
|
||||||
|
if let Some(category) = cli.install {
|
||||||
|
return config::install_assets(category);
|
||||||
|
}
|
||||||
|
|
||||||
|
if let Some(url) = cli.install_from.as_deref() {
|
||||||
|
return config::install_remote(url, cli.filter, cli.install_force);
|
||||||
|
}
|
||||||
|
|
||||||
if let Some(client_arg) = &cli.authenticate {
|
if let Some(client_arg) = &cli.authenticate {
|
||||||
let cfg = Config::load_with_interpolation(true).await?;
|
let cfg = Config::load_with_interpolation(true).await?;
|
||||||
let app_config = AppConfig::from_config(cfg)?;
|
let app_config = AppConfig::from_config(cfg)?;
|
||||||
@@ -152,14 +160,6 @@ async fn run(
|
|||||||
text: Option<String>,
|
text: Option<String>,
|
||||||
abort_signal: AbortSignal,
|
abort_signal: AbortSignal,
|
||||||
) -> Result<()> {
|
) -> Result<()> {
|
||||||
if let Some(category) = cli.install {
|
|
||||||
return config::install_assets(category);
|
|
||||||
}
|
|
||||||
|
|
||||||
if let Some(url) = cli.install_from.as_deref() {
|
|
||||||
return config::install_remote(url, cli.filter, cli.install_force);
|
|
||||||
}
|
|
||||||
|
|
||||||
if cli.sync_models {
|
if cli.sync_models {
|
||||||
let url = ctx.app.config.sync_models_url();
|
let url = ctx.app.config.sync_models_url();
|
||||||
return sync_models(&url, abort_signal.clone()).await;
|
return sync_models(&url, abort_signal.clone()).await;
|
||||||
|
|||||||
+1
-1
@@ -220,7 +220,7 @@ static REPL_COMMANDS: LazyLock<[ReplCommand; 42]> = LazyLock::new(|| {
|
|||||||
),
|
),
|
||||||
ReplCommand::new(
|
ReplCommand::new(
|
||||||
".install",
|
".install",
|
||||||
"Reinstall bundled agents, macros, functions, or MCP config (overwrites local changes)",
|
"Reinstall bundled assets, or install assets from a remote git repo (.install remote <url>)",
|
||||||
AssertState::pass(),
|
AssertState::pass(),
|
||||||
),
|
),
|
||||||
ReplCommand::new(
|
ReplCommand::new(
|
||||||
|
|||||||
Reference in New Issue
Block a user