feat!: remove the deprecated --install-from flag and .install remote form

--install <git-url|name> is the single entry point for remote installs
and updates; the unified .install dispatch likewise replaces
.install remote. Flag completion for .install now applies to the
unified form.
This commit is contained in:
2026-08-24 11:15:13 -06:00
parent 9541a094d8
commit 4987d850f9
7 changed files with 19 additions and 99 deletions
-16
View File
@@ -69,22 +69,6 @@ pub fn install_remote(git_url: &str, filter: Option<InstallFilter>, force: bool)
Ok(())
}
pub fn install_remote_from_repl_args(args: &str) -> Result<()> {
let tokens = shell_words::split(args)
.with_context(|| format!("failed to parse '.install remote' args: {args}"))?;
let mut iter = tokens.into_iter();
let url = iter.next().with_context(|| {
format!(
"Usage: .install remote <git-url> [--filter <{}>] [--force]",
InstallFilter::NAMES.join("|")
)
})?;
let (filter, force) = parse_repl_install_flags(".install remote", iter)?;
install_remote(&url, filter, force)
}
fn parse_repl_install_flags(
command: &str,
mut iter: impl Iterator<Item = String>,
+1 -2
View File
@@ -33,8 +33,7 @@ pub use self::app_state::AppState;
pub use self::bundles::list_installed_bundles;
pub use self::input::Input;
pub use self::install_remote::{
install_or_update, install_or_update_from_repl_args, install_remote,
install_remote_from_repl_args, uninstall_bundle, update_bundle,
install_or_update, install_or_update_from_repl_args, uninstall_bundle, update_bundle,
};
pub use self::macro_policy::{
MacroAllowlistLevel, MacroPolicy, MacroSource, MacroState, RESERVED_MACRO_NAMES, ResolvedMacro,
+3 -4
View File
@@ -3263,7 +3263,6 @@ impl RequestContext {
".install" => {
let mut values: Vec<String> =
AssetCategory::NAMES.iter().map(|s| s.to_string()).collect();
values.push("remote".to_string());
values.extend(
BundleStore::load()
.map(|store| {
@@ -3495,7 +3494,7 @@ impl RequestContext {
values = complete_skills_with_descriptions(paths::list_skills());
} else if cmd == ".skill" && args.first() == Some(&"unload") && args.len() == 2 {
values = complete_skills_with_descriptions(self.skill_registry.loaded_names());
} else if cmd == ".install" && args.first() == Some(&"remote") && args.len() >= 2 {
} else if cmd == ".install" && args.len() >= 2 {
let prev = args.get(args.len() - 2).copied().unwrap_or("");
if prev == "--filter" {
values = super::map_completion_values(
@@ -4992,7 +4991,7 @@ mod tests {
#[test]
#[serial]
fn repl_complete_install_offers_categories_remote_and_bundles() {
fn repl_complete_install_offers_categories_and_bundles() {
let _guard = TestConfigDirGuard::new();
let mut store = BundleStore::load().unwrap();
store
@@ -5012,7 +5011,7 @@ mod tests {
let values = ctx.repl_complete(".install", &[""], "");
for expected in ["agents", "remote", "omc"] {
for expected in ["agents", "omc"] {
assert!(
values.iter().any(|(name, _)| name == expected),
"missing '{expected}'; got: {values:?}"