deps¶
Description¶
Commands for managing dependencies.
Available Commands:
update: Update packages.json from parent repo and packages in child repo
generate_gitignore: Generate .gitignore entries from packages.json
verify: Verify dependencies against version set and update if needed
Subcommands¶
bump¶
Verify and optionally update package dependencies.
Optional Parameters:
auto_approve: Skip confirmation prompts for updates. Default: False
- Automatically applies all updates
- No interactive prompts
- Use with caution in production
Usage: Verify with prompts: adev deps verify
Auto-approve updates:
adev deps verify --auto-approve
Notes¶
- Authentication:
- Requires GITHUB_TOKEN environment variable
- Token needs repo and packages read access
- Can be generated at github.com/settings/tokens
- Verification Process:
- Checks both autonomy and poetry dependencies
- Verifies against specified version sets
- Compares local vs remote package hashes
- Validates dependency compatibility
- Update Process:
- Updates packages.json for autonomy packages
- Updates pyproject.toml for poetry dependencies
- Handles dependency resolution
- Maintains version consistency
- Features:\n
- Parallel version checking
- Detailed diff viewing
- Selective update approval
- Dependency tree analysis
- Version conflict detection
- Best Practices:\n
- Run before deployments
- Include in CI/CD pipelines
- Regular scheduled verification
- Version pinning enforcement
generate-gitignore¶
Generate .gitignore entries from packages.json.
Usage:
Generate gitignore entries:
adev deps generate-gitignore
Notes¶
- Only adds new entries, doesn't remove existing ones
- Focuses on third-party packages from packages.json
- Appends entries to existing .gitignore file
update¶
Update dependencies from parent repo to child repo.
Required Parameters:
parent_repo (-p): Path to the parent repository containing source packages.json.
child_repo (-c): Path to the child repository to update.
Optional Parameters:
location (--location): Location of dependencies (local or remote). Default: local
auto_confirm (--auto-confirm): Skip confirmation prompts. Default: False
manual (--manual): Enable manual mode for updates. Default: False
Usage:
Update with defaults:
adev deps update -p /path/to/parent -c /path/to/child
Auto-confirm updates:
adev deps update -p /path/to/parent -c /path/to/child --auto-confirm
Manual mode:
adev deps update -p /path/to/parent -c /path/to/child --manual
verify¶
Verify the dependencies from the adev config file.
This allows us to specify the dependencies in the adev config file then verify them aginst the installed dependencies enforcing the version set.