Skip to content

[FEATURE] Support plugin root bin/ for marketplace_plugin packages #1544

@maro114510

Description

@maro114510

Is your feature request related to a problem? Please describe.

Yes. apm install deploys skills from marketplace_plugin packages, but it does not deploy or expose the package root bin/ directory.

This breaks skills that rely on helper executables shipped in bin/.

Example:

# ~/apm.yml
dependencies:
  apm:
    - owner/repo
apm install

Observed:

~/.claude/skills/example-skill/SKILL.md   ✓ deployed
~/.claude/skills/example-skill/bin/       ✗ not deployed
bin/example-helper.sh                     ✗ not on Bash tool PATH

Runtime failure:

Bash(example-helper.sh "some-argument")
Error: Exit code 127
(eval):1: command not found: example-helper.sh

Claude Code's plugin documentation defines bin/ as a plugin-root directory whose executables are added to the Bash tool's PATH while the plugin is enabled:

bin/ — Plugin root — Executables added to the Bash tool's PATH while the plugin is enabled.

So a plugin that works when installed via claude plugin install can fail when installed via apm install.

Describe the solution you'd like

For marketplace_plugin packages, apm should preserve the Claude Code plugin bin/ contract:

  1. Deploy the package root bin/ directory.
  2. Make the deployed bin/ available on the Bash tool's PATH.
  3. Record the deployed bin/ path in apm.lock.yaml.

The exact on-disk location can follow apm's deployment model, but executables under plugin-root bin/ should be invokable as bare commands from Bash tool calls.

Describe alternatives you've considered

  • Inline the script logic into SKILL.md, but this makes deterministic helper logic harder to test and maintain.
  • Use a postinstall hook, but that adds security and complexity concerns.
  • Symlink into ~/.local/bin, but that depends on apm cache/deployment internals.
  • Call scripts by absolute path, but that makes skills apm-specific and diverges from Claude Code's plugin contract.

Additional context

apm.lock.yaml confirms that bin/ is currently absent from deployed_files:

- repo_url: owner/repo
  package_type: marketplace_plugin
  deployed_files:
  - .claude/skills/example-skill
  # no bin/ entry

This makes apm-managed marketplace_plugin packages less compatible with Claude Code's native plugin behavior.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type/featureNew capability, new flag, new primitive.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions