Skip to content

apm deny

Terminal window
apm deny [OPTIONS] PACKAGES...

apm deny blocks executable primitives from one or more dependency packages. By default, it writes the decision to the project’s committed apm.yml under executables.deny. Pass --user to write a machine-local decision to ~/.apm/config.json instead. Run the command from an APM project: an apm.yml file is required for both scopes.

A deny takes precedence over an allow. For the full precedence model and the executable types covered by the gate, see apm approve — Precedence.

Argument or flagDescription
PACKAGES...One or more package references, such as owner/repo. Required.
--userRecord the deny in ~/.apm/config.json instead of apm.yml.

For an installed package that declares executable types, APM records those types. When no executable declaration is found — because the package is not installed or declares no executables — APM blocks all supported executable types for that reference. Writing a deny also removes a matching allow from the selected store.

Block a package for everyone using the project:

Terminal window
apm deny owner/repo

Block multiple packages:

Terminal window
apm deny owner/first owner/second

Block a package only on the current machine:

Terminal window
apm deny --user owner/repo
  • apm approve — Precedence — manage executable trust and inspect the deny-wins precedence model.
  • apm policy — explain the effective trust decision for an installed package.
  • apm install — install dependencies while enforcing the executable gate.