Run with NPM
The npm packagepackmind-cli allows to compute best practices suggestions on a code base to detect locations where best practices are not followed. It also provides facilities to produce a report file for tools like SonarQube, or in the SARIF format (Static Analysis Results Interchange Format).
Installation
We recommend installing the packmind-cli tool globally.
npm i -g packmind-cli Configuration
There is one mandatory parameter to set:
PACKMIND_API_KEY: A valid user API Key to connect to your Packmind instance.
We recommend setting these values as environment variables, but you can also pass them as command-line arguments.
The simplest way to export them is to set them in the shell configuration file (.zshrc for zsh, .bashrcfor bash):
export PACKMIND_API_KEY="..."Make sure to run the source command so that the environment variable is properly loaded.
source ~/.zshrcRun a scan in standalone mode
Run the following command to ensure everything works fine:
packmind-cli scan .For any suggestion to improve this package, feel free to submit us your suggestion, and we'd be happy to consider it:
Last updated
Was this helpful?
