Commands
The same commands work in every language
One install, then mlreps in any project — Java, Python, PHP, Node, anything the reader can read. Node.js 20 or newer on your machine, or a build that needs no Node at all from the install script or Homebrew. Teams without Node use the GitHub App instead, which installs nothing.On Linux the binary needs glibc plus libatomic1 and libstdc++6 (Debian, Ubuntu) or libatomic and libstdc++ (Fedora, RHEL, Amazon Linux) — a full image has them; a slim one usually lacks libatomic.
Install
once, on your machine
npm install -g mlreps
export MLREPS_ENDPOINT=https://dev.mlreps.comOr without installing anything, npx mlreps@latest works in place of mlreps in every command below. The install touches nothing in your project.
Account
mlreps setup [path]
Connect this repository: one click to authorise this machine, a publishing key kept outside the repository, and the first scan published.
setup example
mlreps setupmlreps whoami
Which account and organisation this machine publishes to, and what it may publish.
whoami example
mlreps whoamimlreps switch
Sign this machine out and let another account take it. Whoever approves in the browser becomes the account.
switch example
mlreps switchmlreps login
Authorise this machine — one click in your browser, and it lasts thirty days.
login example
mlreps loginmlreps logout
Forget this machine's authorisation. The credentials it minted keep working: they belong to the project.
logout example
mlreps logoutScan and publish
mlreps scan [path]
The graph, what a change would reach, and what the rules found. The default command. On your own machine it reports counts by kind and the top findings; the full report is on the dashboard it publishes to.
scan example
mlreps scan . --publishFlags: --upload-report · --publish · --local · --dry-run · --over-limit · --json · --record · --limit <n>
mlreps impact [path]
What this branch's change reaches, against its merge base.
impact example
mlreps impact --base mainFlags: --base <ref> · --fail-on-exposed · --json · --record · --limit <n>
mlreps history [path]
What the last scans found, and what changed between them.
history example
mlreps history --last 10Flags: --last <n> · --json
mlreps badge [path]
The README line for this repository's badge — the date of its last audit. Free, and needs no key.
badge example
mlreps badgemlreps doctor [path]
What this machine needs in order to read each language here.
doctor example
mlreps doctorPull requests and CI
mlreps check [path]
Check this pull request from your own CI: what the change adds against its merge base, posted with the CI's own token. Your code is never sent. It never fails the build — the check run carries the verdict. Needs the full history (fetch-depth: 0).
check example
npx mlreps@latest check .Flags: --dry-run · --upload-report · --json · --limit <n>
Rules file
mlreps rules [path]
What mlreps.rules.yml says, and --starter to write five defaults you can edit.
rules example
mlreps rules --starterFlags: --starter
Operators
mlreps register
Print the GitHub App manifest for a deployment of MLReps. For operators running their own.
register example
mlreps register --base-url https://mlreps.acme.internalFlags: --base-url <url> · --complete <code>
mlreps help
This list, in the terminal.
help example
mlreps helpPer-language notes
The commands do not change. What changes is what a language needs installed before calls can be followed all the way through — and for most of them, nothing.
| Language | For full resolution |
|---|---|
| Python | npm i -g pyright |
| PHP | npm i -g intelephense |
| Java | download jdtls, set MLREPS_JDTLS_HOME (and a JDK 25 on JAVA_HOME) |
| Ruby | gem install ruby-lsp (Ruby 3+) |
| C | install clangd (LLVM, or Xcode command-line tools) |
| C++ | install clangd (LLVM, or Xcode command-line tools) |
| Dart | install the Dart SDK (puts dart on PATH) |
| Swift | install the Swift toolchain / Xcode (sourcekit-lsp); build the project for its index |
| Kotlin | download kotlin-language-server; set MLREPS_KOTLIN_JAVA_HOME to a JDK 17-21 |
| Rust | install rust-analyzer and the Rust toolchain (rustup component add rust-analyzer) |
| C# | dotnet tool install --global csharp-ls (symbols only today) |
Every other language the reader supports needs nothing installed. mlreps doctor says what this machine has, and a scan that could not follow a call says so rather than leaving it out.
Connecting a repository for the first time is Setup, and the GitHub App path — which installs nothing on your machine — is here.