Skip to content

Add avocado connect clean command#126

Merged
mobileoverlord merged 2 commits intomainfrom
nsinas/connect-clean
Apr 13, 2026
Merged

Add avocado connect clean command#126
mobileoverlord merged 2 commits intomainfrom
nsinas/connect-clean

Conversation

@nicksinas
Copy link
Copy Markdown
Contributor

avocado connect clean

New command that reverses what avocado connect init sets up. It removes:

  1. connect: section from avocado.yaml (org, project, server_key)
  2. avocado-ext-connect-config extension — both the definition in extensions: and
    the - avocado-ext-connect-config entry from the runtime's extensions list
  3. overlay/etc/avocado-conn/ directory (contains config.toml with the claim token)

It intentionally preserves avocado-ext-connect and avocado-ext-tunnels — those are
infrastructure extensions present even in projects without connect configuration
(like qemu-quickstart).

CLI flags:

  • -r, --runtime <name> — runtime to remove connect-config from (default: dev)
  • -C, --config <path> — path to avocado.yaml (default: avocado.yaml)

Files changed:

  • src/commands/connect/clean.rs — new ConnectCleanCommand
  • src/commands/connect/mod.rs — added pub mod clean
  • src/utils/config_edit.rs — added remove_connect_fields(),
    remove_connect_config_extension(), and supporting private functions
    (remove_extension_definition, remove_runtime_extension_entry)
  • src/main.rs — added Clean variant to ConnectCommands, import, and dispatch

@mobileoverlord mobileoverlord merged commit 934d86e into main Apr 13, 2026
5 checks passed
@mobileoverlord mobileoverlord deleted the nsinas/connect-clean branch April 13, 2026 19:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants