Skip to content

feat: add install command for single package install #8

Description

@maiconfz

Workflow

Branch pattern: feat/<issue-number>-install-single-package (use the assigned number and a short lowercase kebab-case slug)

Draft PR: Open with gh pr create --draft before implementation commits. Use Closes #<issue-number> in the PR ## Related Issues section.

Summary

Add npx agents-repo install <package> / i alias for single package install.

Motivation

Core MVP command to install registry packages into projects (skills.sh / npm install parity).

Proposed scope

In scope:

  • Resolve registry source from ConfigResolver + webapp-style ref/tag resolution
  • Resolve package ref (qualified id / alias) from index
  • Resolve version via manifest + semver range
  • Build artifact URL with buildRegistryArtifactUrl
  • Validate compatibility.targets / index installTargets includes chosen target
  • Download ZIP, verify sha256, ZIP security scan (registry zip-scan rules), extract per install-targets
  • Update packages + agents-lock.json unless --no-save
  • Flags: --agent, --flow, -g/--global, -y, --target, --dry-run, --no-save
  • Reject yanked; warn deprecated

Out of scope:

  • Bulk install (no args)

Impacted areas

  • src/modules/install/
  • src/modules/cli/presentation/

Done criteria

  • Integration test with mocked registry HTTP
  • Installs known package into temp dir
  • Rejects malicious ZIP fixture

Milestone

M3 — MVP CLI

Depends on

Registry client issue, config/lock management issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions