You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Remove --force from integration install, ensure shared infra on install/switch
- Remove --force parameter entirely from integration install; users must
uninstall before reinstalling to prevent orphaned files
- Auto-install shared infrastructure (.specify/scripts/, .specify/templates/)
when missing during install or switch
- Add test for shared infra creation on bare project install
Copy file name to clipboardExpand all lines: src/specify_cli/__init__.py
+15-9Lines changed: 15 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -1608,7 +1608,6 @@ def integration_install(
1608
1608
key: str=typer.Argument(help="Integration key to install (e.g. claude, copilot)"),
1609
1609
script: str=typer.Option(None, "--script", help="Script type: sh or ps (default: from init-options.json or platform default)"),
1610
1610
integration_options: str=typer.Option(None, "--integration-options", help='Options for the integration (e.g. --integration-options="--commands-dir .myagent/cmds")'),
1611
-
force: bool=typer.Option(False, "--force", help="Overwrite existing integration without uninstalling first"),
1612
1611
):
1613
1612
"""Install an integration into an existing project."""
1614
1613
from .integrationsimportINTEGRATION_REGISTRY, get_integration
@@ -1632,23 +1631,24 @@ def integration_install(
1632
1631
current=_read_integration_json(project_root)
1633
1632
installed_key=current.get("integration")
1634
1633
1635
-
ifinstalled_keyandinstalled_key==keyandnotforce:
1634
+
ifinstalled_keyandinstalled_key==key:
1636
1635
console.print(f"[yellow]Integration '{key}' is already installed.[/yellow]")
1637
-
console.print("Use [cyan]--force[/cyan] to reinstall, or [cyan]specify integration switch <target>[/cyan] to change.")
1636
+
console.print("Run [cyan]specify integration uninstall[/cyan] first, then reinstall.")
1638
1637
raisetyper.Exit(0)
1639
1638
1640
1639
ifinstalled_keyandinstalled_key!=key:
1641
1640
console.print(f"[red]Error:[/red] Integration '{installed_key}' is already installed.")
1642
-
console.print(f"Use [cyan]specify integration switch {key}[/cyan] to switch integrations.")
1643
-
ifforce:
1644
-
console.print(
1645
-
"[yellow]--force only supports reinstalling the currently installed integration "
1646
-
"and cannot overwrite a different integration.[/yellow]"
1647
-
)
1641
+
console.print(f"Run [cyan]specify integration uninstall[/cyan] first, or use [cyan]specify integration switch {key}[/cyan].")
0 commit comments