aam registry remove¶
Registry Management
Synopsis¶
Description¶
Remove a configured registry from the global configuration. The registry directory itself is not deleted, only the AAM configuration entry.
After removal, packages from this registry will no longer be available for installation or search.
Arguments¶
| Argument | Required | Description |
|---|---|---|
| NAME | Yes | Registry name to remove |
Options¶
This command has no command-specific options.
Examples¶
Example 1: Remove Registry¶
Output:
Example 2: Registry Not Found¶
Output:
Example 3: Remove and Re-add¶
# Remove old configuration
aam registry remove team
# Add with updated URL
aam registry add team file:///mnt/new-location --default
Example 4: Clean Up Multiple Registries¶
Output:
Example 5: Remove Default Registry¶
Output:
If this was the default registry, you'll need to set a new default:
Exit Codes¶
| Code | Meaning |
|---|---|
| 0 | Success - registry removed |
| 1 | Error - registry not found |
Related Commands¶
aam registry list- List configured registriesaam registry add- Add a registryaam registry init- Create a local registry
Notes¶
Registry Data Preserved¶
Removing a registry from AAM configuration does not delete the registry directory or packages:
# Remove from config
aam registry remove local
# Registry files still exist
ls ~/my-packages/
# registry.yaml, index.yaml, packages/
To re-add:
Impact on Installed Packages¶
Removing a registry does not affect already-installed packages:
# Install package
aam install my-package
# Remove registry
aam registry remove local
# Package still installed and functional
aam list
# my-package@1.0.0 still listed
However, you cannot reinstall or update packages from the removed registry.
Removing Default Registry¶
If you remove the default registry, AAM will not have a default:
Solution: Set a new default:
Verification¶
After removal, verify:
The removed registry should not appear in the list.
Cannot Undo¶
There is no built-in undo. To restore a removed registry, re-add it:
# Removed by mistake
aam registry remove important
# Restore
aam registry add important file:///path/to/registry
Cleaning Up¶
Remove registries you no longer use:
# List all registries
aam registry list
# Remove unused ones
aam registry remove old-dev
aam registry remove temporary-test
aam registry remove archived-2023
This keeps configuration clean and improves performance for search and install operations.
Registry Name Case¶
Registry names are case-sensitive:
Alternative: Manual Editing¶
You can also edit ~/.aam/config.yaml directly:
registries:
- name: local
url: file:///home/user/packages
type: local
default: true
- name: remove-this # Delete this entry
url: file:///tmp/old
type: local
default: false
After editing, verify:
Migration Scenario¶
When migrating registries:
# Old setup
aam registry list
# old-location (local)
# Create new registry
aam registry init /new/location
# Copy packages
cp -r /old/location/packages/* /new/location/packages/
# Update AAM config
aam registry remove old-location
aam registry add new-location file:///new/location --default
Team Coordination¶
When removing shared registries, coordinate with team:
- Announce registry removal
- Ensure team has alternatives
- Remove from team documentation
- Update team configs
Safety Check¶
Before removing important registries, check what's installed from them: