Platform compatibility checks for npm packages.
Evaluates os, cpu, and engines fields from package.json
against the current system to detect incompatible packages.
Summary
Functions
Check if the engines field is satisfied.
Check if a package is compatible with the current CPU architecture.
Get the current CPU architecture in npm format.
Get the current OS name in npm format.
Check if a package is compatible with the current OS.
Functions
Check if the engines field is satisfied.
Returns a list of warning strings for unsatisfied engine constraints.
Currently only checks the node engine as informational.
Check if a package is compatible with the current CPU architecture.
The cpu field is an array of allowed (or disallowed with ! prefix)
CPU architectures.
@spec current_cpu() :: String.t()
Get the current CPU architecture in npm format.
@spec current_os() :: String.t()
Get the current OS name in npm format.
Check if a package is compatible with the current OS.
The os field is an array of allowed (or disallowed with ! prefix)
operating systems.