@bastani/atomic 0.9.16-alpha.5 → 0.9.16-alpha.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/builtin/intercom/index.bundle.mjs +4 -1
  3. package/dist/builtin/intercom/package.json +1 -1
  4. package/dist/builtin/mcp/index.bundle.mjs +4 -1
  5. package/dist/builtin/mcp/package.json +1 -1
  6. package/dist/builtin/subagents/CHANGELOG.md +6 -0
  7. package/dist/builtin/subagents/package.json +1 -1
  8. package/dist/builtin/subagents/skills/qlty/SKILL.md +123 -0
  9. package/dist/builtin/subagents/skills/qlty/references/coding-with-ai-agents.md +64 -0
  10. package/dist/builtin/subagents/skills/qlty/references/commands.md +291 -0
  11. package/dist/builtin/subagents/skills/qlty/references/plugins-and-extensions.md +228 -0
  12. package/dist/builtin/subagents/skills/qlty/references/quickstart.md +110 -0
  13. package/dist/builtin/subagents/src/extension/index.bundle.mjs +4 -1
  14. package/dist/builtin/web-access/index.bundle.mjs +4 -1
  15. package/dist/builtin/web-access/package.json +1 -1
  16. package/dist/builtin/workflows/CHANGELOG.md +16 -0
  17. package/dist/builtin/workflows/README.md +3 -1
  18. package/dist/builtin/workflows/builtin/goal-prompts.ts +6 -0
  19. package/dist/builtin/workflows/builtin/ralph-reviewer-prompt.ts +4 -0
  20. package/dist/builtin/workflows/builtin/ralph-runner.ts +4 -0
  21. package/dist/builtin/workflows/builtin/shared-prompts.ts +25 -0
  22. package/dist/builtin/workflows/package.json +1 -1
  23. package/dist/builtin/workflows/src/extension/index.bundle.mjs +47 -4
  24. package/dist/builtin/workflows/src/index.bundle.mjs +7 -2
  25. package/dist/core/system-prompt.d.ts.map +1 -1
  26. package/dist/core/system-prompt.js +4 -1
  27. package/dist/core/system-prompt.js.map +1 -1
  28. package/docs/quickstart.md +1 -0
  29. package/docs/skills.md +4 -0
  30. package/docs/workflows.md +6 -0
  31. package/npm-shrinkwrap.json +32 -32
  32. package/package.json +3 -3
package/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.9.16-alpha.6] - 2026-08-26
6
+
7
+ ### Changed
8
+
9
+ - The default system prompt now teaches repository-intent inference when a shell tool is available: review recent commits, open and merged PRs, issues and their comments, and project/board status to learn maintainer conventions, and identify the requesting user (`git config user.name`/`user.email`, `gh api user`) to interpret ambiguous requests through their own patterns.
10
+ - The ask_user_question fallback guideline now instructs the agent, when no human input channel exists, to choose the interpretation best supported by the repository and stated objective — mining git history, commits, PRs, issues, and the user's own comments to infer how they would decide — state the assumption, and continue fully autonomously instead of stalling.
11
+
5
12
  ## [0.9.16-alpha.5] - 2026-08-26
6
13
 
7
14
  ### Added
@@ -16007,7 +16007,10 @@ Current working directory: ${promptCwd}
16007
16007
  }
16008
16008
  }
16009
16009
  if (shouldIncludeAskUserFallbackGuidance) {
16010
- addGuideline("Clarify ambiguous requirements using the ask_user_question tool if available.");
16010
+ addGuideline("Clarify ambiguous requirements using the ask_user_question tool if available. When it is unavailable and no human input channel exists, do not stall on a question: choose the interpretation best supported by the repository and the stated objective — mine git history, commits, PRs, issues, and the user's own comments to infer how they would decide — state the assumption in your response, and continue fully autonomously on best judgment.");
16011
+ }
16012
+ if (hasBash || hasPowerShell) {
16013
+ addGuideline("**Repository intent**: When working in a repository, infer how its maintainers actually work before imposing defaults: review recent commits, open and merged PRs, issues and their comments, and project/board status when tooling allows (for example `git log` and the `gh` CLI) to learn conventions, priorities, and scope norms. Better, identify the requesting user (`git config user.name`/`user.email`, `gh api user`) and study their own commits, PRs, reviews, and issue comments so you interpret ambiguous requests the way they would, aligning style, scope, and process with their patterns.");
16011
16014
  }
16012
16015
  for (const guideline of promptGuidelines ?? []) {
16013
16016
  const normalized = guideline.trim();
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bastani/intercom",
3
- "version": "0.9.16-alpha.5",
3
+ "version": "0.9.16-alpha.7",
4
4
  "private": true,
5
5
  "description": "Atomic extension providing a private coordination channel between parent and child agent sessions. Fork of: https://github.com/nicobailon/pi-intercom",
6
6
  "contributors": [
@@ -16007,7 +16007,10 @@ Current working directory: ${promptCwd}
16007
16007
  }
16008
16008
  }
16009
16009
  if (shouldIncludeAskUserFallbackGuidance) {
16010
- addGuideline("Clarify ambiguous requirements using the ask_user_question tool if available.");
16010
+ addGuideline("Clarify ambiguous requirements using the ask_user_question tool if available. When it is unavailable and no human input channel exists, do not stall on a question: choose the interpretation best supported by the repository and the stated objective — mine git history, commits, PRs, issues, and the user's own comments to infer how they would decide — state the assumption in your response, and continue fully autonomously on best judgment.");
16011
+ }
16012
+ if (hasBash || hasPowerShell) {
16013
+ addGuideline("**Repository intent**: When working in a repository, infer how its maintainers actually work before imposing defaults: review recent commits, open and merged PRs, issues and their comments, and project/board status when tooling allows (for example `git log` and the `gh` CLI) to learn conventions, priorities, and scope norms. Better, identify the requesting user (`git config user.name`/`user.email`, `gh api user`) and study their own commits, PRs, reviews, and issue comments so you interpret ambiguous requests the way they would, aligning style, scope, and process with their patterns.");
16011
16014
  }
16012
16015
  for (const guideline of promptGuidelines ?? []) {
16013
16016
  const normalized = guideline.trim();
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bastani/mcp",
3
- "version": "0.9.16-alpha.5",
3
+ "version": "0.9.16-alpha.7",
4
4
  "private": true,
5
5
  "description": "Atomic extension that adapts MCP (Model Context Protocol) servers into the coding agent. Fork of: https://github.com/nicobailon/pi-mcp-adapter",
6
6
  "contributors": [
@@ -2,6 +2,12 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [0.9.16-alpha.7] - 2026-08-26
6
+
7
+ ### Added
8
+
9
+ - New bundled `qlty` skill for code-quality verification through the [qlty](https://qlty.sh) CLI: linting (`qlty check`), auto-formatting (`qlty fmt`), maintainability metrics (`qlty metrics`), and code smells such as duplication and deep nesting (`qlty smells`). The skill triggers on requests for verifiers or high code quality, directs the agent to `https://docs.qlty.sh/llms.txt` as the authoritative documentation index, instructs it to enable the qlty plugins and linter extensions that fit the codebase rather than invoking per-tool linters ad hoc, and ships source-attributed reference excerpts under `skills/qlty/references/`.
10
+
5
11
  ## [0.9.16-alpha.5] - 2026-08-26
6
12
 
7
13
  ### Changed
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bastani/subagents",
3
- "version": "0.9.16-alpha.5",
3
+ "version": "0.9.16-alpha.7",
4
4
  "private": true,
5
5
  "description": "Atomic extension for delegating tasks to subagents with parallel execution. Fork of: https://github.com/nicobailon/pi-subagents",
6
6
  "contributors": [
@@ -0,0 +1,123 @@
1
+ ---
2
+ name: qlty
3
+ description: Code quality checks, formatting, and metrics via qlty CLI. Use when asked to verify code quality, add or run verifiers, make sure code is high quality before commit or handoff, lint or auto-format a codebase, measure complexity, cohesion, or lines of code, or find code smells like duplication and deep nesting.
4
+ ---
5
+
6
+ # Qlty Code Quality
7
+
8
+ `qlty` is a universal code quality tool: one CLI that drives 70+ linters, auto-formatters, and security scanners across 40+ languages and technologies, plus its own static analysis for metrics and code smells.
9
+
10
+ **Prefer the `qlty` CLI over ad-hoc per-tool linter invocations.** Do not reach for `eslint`, `ruff`, `rubocop`, `shellcheck`, `prettier`, `gofmt`, and friends one at a time. Run them through `qlty check` / `qlty fmt` so every language in the repository is covered by one command, with one config, one cache, and one consistent issue format. Fall back to invoking a tool directly only when the repository's own scripts require it (for example a project's `npm run check`) or when qlty has no plugin for it.
11
+
12
+ ## Documentation
13
+
14
+ **Reference <https://docs.qlty.sh/llms.txt> heavily.** It is the authoritative index of every qlty documentation page, each available as Markdown by appending `.md` to the page URL. Fetch the index first, then fetch the specific pages you need — command pages under `https://docs.qlty.sh/cli/commands/`, concepts under `https://docs.qlty.sh/cli/concepts/`, and language support under `https://docs.qlty.sh/languages/`.
15
+
16
+ Local excerpts of the most-used pages live in [references/](references/), each attributed to its upstream URL:
17
+
18
+ - [references/quickstart.md](references/quickstart.md) — install, `qlty init`, first run
19
+ - [references/commands.md](references/commands.md) — `check`, `fmt`, `metrics`, `smells`, `init`, `plugins`
20
+ - [references/plugins-and-extensions.md](references/plugins-and-extensions.md) — enabling plugins, linter extensions, `qlty.toml`
21
+ - [references/coding-with-ai-agents.md](references/coding-with-ai-agents.md) — upstream's own guidance for agents
22
+
23
+ The local copies are point-in-time excerpts. When they disagree with the live docs, the live docs win — fetch from `llms.txt`.
24
+
25
+ ## When to Use
26
+
27
+ - **Check code for linting issues before commit or handoff.** `qlty check` is the last gate before you hand work to a human or another stage.
28
+ - **Auto-fix formatting and style issues.** `qlty fmt` rewrites files; `qlty check --fix` applies lint auto-fixes.
29
+ - **Calculate code metrics** — complexity, lines of code, cohesion, duplication — with `qlty metrics`.
30
+ - **Find code smells** — duplicated code, deeply nested control flow, overly complex functions — with `qlty smells`.
31
+ - **When a user asks for "verifiers", or asks you to make sure the code is high quality, use this skill.** Those requests mean: enable the right linters for this codebase, then run the check/fmt/metrics/smells loop and fix what it reports.
32
+
33
+ ## Install
34
+
35
+ Skip this if `qlty --version` already works.
36
+
37
+ ```bash
38
+ # macOS & Linux
39
+ curl https://qlty.sh | bash
40
+ ```
41
+
42
+ Upstream documents the same installer as `curl https://qlty.sh | sh`; both work, the script is POSIX `sh`.
43
+
44
+ ```powershell
45
+ # Windows
46
+ powershell -c "iwr https://qlty.sh | iex"
47
+ ```
48
+
49
+ The binary lands in `~/.qlty/bin` and **that directory must be on `PATH`**. The installer appends an export to your shell rc file, which does not help a non-interactive or already-running shell — export it yourself when a command reports `qlty: command not found`:
50
+
51
+ ```bash
52
+ export PATH="$HOME/.qlty/bin:$PATH"
53
+ ```
54
+
55
+ Two useful installer environment variables: `QLTY_INSTALL_BIN_PATH` puts the binary somewhere already on `PATH` (for example `$HOME/.local/bin`), and `QLTY_NO_MODIFY_PATH=1` suppresses the rc-file edit. qlty supports macOS and Linux on x64 and arm64 (glibc and musl); Windows support is newer, so verify it rather than assuming.
56
+
57
+ ## Enable the right plugins for this codebase
58
+
59
+ Blindly running `qlty check` in a repository with no configuration finds nothing. Tailor the plugin set to the codebase first — this is what turns qlty from a lint runner into a quality bar.
60
+
61
+ ```bash
62
+ qlty init # detect file types, write .qlty/qlty.toml with a baseline plugin set
63
+ qlty plugins list # every available plugin
64
+ qlty plugins enable eslint # enable one the baseline missed
65
+ ```
66
+
67
+ Then review `.qlty/qlty.toml` against what the repository actually uses: a TypeScript repo usually wants `eslint` plus `prettier`, Python wants `ruff`, Go wants `staticcheck`/`gofmt`, shell wants `shellcheck`/`shfmt`, and almost every repo benefits from `trivy` or `gitleaks` for secrets and vulnerabilities. Enable security and type-checking plugins deliberately; they are the ones that catch defects rather than style.
68
+
69
+ Also enable **linter extensions** — the plugin ecosystem of each linter (`eslint-plugin-react`, `eslint-plugin-security`, RuboCop extensions, Ruff/Pylint/Bandit packages). In `qlty.toml`, either list them with `extra_packages` or point at the project's own dependency manifest with `package_file`:
70
+
71
+ ```toml
72
+ [[plugin]]
73
+ name = "eslint"
74
+ version = "8.57.0"
75
+ extra_packages = ["eslint-plugin-react@7.33.2", "eslint-plugin-security@3.0.1"]
76
+ ```
77
+
78
+ See [references/plugins-and-extensions.md](references/plugins-and-extensions.md) and <https://docs.qlty.sh/cli/linter-extensions.md>.
79
+
80
+ `qlty init` writes `.qlty/qlty.toml` into the repository. In someone else's checkout that is a real, reviewable change — say so before running it, and do not leave it behind uncommitted in a repository you were only asked to inspect.
81
+
82
+ ## Core commands
83
+
84
+ All of `check`, `fmt`, and `smells` must run inside a Git repository with qlty initialized, and default to **changed files only**; pass `--all` or explicit paths to widen. `check` and `fmt` install any missing plugins and language runtimes on demand, so the first run is slow and needs network access.
85
+
86
+ ```bash
87
+ qlty check # lint changed files
88
+ qlty check --all # lint the whole repository
89
+ qlty check --all --filter=eslint # one plugin only
90
+ qlty check --fix --level=low # apply auto-fixes, surface low-severity and up
91
+ qlty check --upstream origin/main # only what this branch changed
92
+
93
+ qlty fmt # auto-format changed files
94
+ qlty fmt --all # auto-format everything
95
+
96
+ qlty metrics --all --max-depth 2 # per-directory summary
97
+ qlty metrics --all --sort complexity --limit 10 # the 10 most complex files
98
+ qlty metrics --functions path/to/file.ts # function-level complexity
99
+
100
+ qlty smells --all # duplication, deep nesting, high complexity
101
+ qlty smells --upstream origin/main # smells introduced by this branch
102
+ ```
103
+
104
+ `--level` sets what is displayed (`note`, `fmt`, `low`, `medium`, `high`); `--fail-level` sets what makes the command exit non-zero. `--sarif` emits SARIF for tooling.
105
+
106
+ ## Offline use
107
+
108
+ The `qlty` binary is self-contained, but its commands split on network needs:
109
+
110
+ - **Offline-safe:** `qlty metrics` and `qlty smells` use qlty's own built-in static analysis — no plugin or runtime downloads, so they work with no network at all.
111
+ - **Network on first use:** `qlty check` and `qlty fmt` install the enabled plugins and any qlty-managed language runtimes on demand, per repository, on their first run. With no network that first run fails.
112
+
113
+ In a network-restricted environment (sandboxes, locked-down CI, benchmark runs), either pre-warm the cache while you still have network — run `qlty init` and one `qlty check --all` in the target repository so plugins and runtimes land in `~/.qlty` — or scope quality verification to `qlty metrics` and `qlty smells` and say so in your report rather than presenting them as full lint coverage.
114
+
115
+ ## Working loop
116
+
117
+ Upstream's own recommendation for agents, and a good default here:
118
+
119
+ 1. `qlty fmt` before committing — formatting churn should never reach a reviewer.
120
+ 2. `qlty check --fix --level=low` before finishing, then fix by hand whatever it could not auto-fix.
121
+ 3. For a quality-focused request, add `qlty smells --all` and `qlty metrics --all --sort complexity --limit 10`, and act on the worst offenders rather than reporting the numbers.
122
+
123
+ Report what you ran and what it found. A clean `qlty check` is evidence; "I made it high quality" is not.
@@ -0,0 +1,64 @@
1
+ # Coding with AI Agents
2
+
3
+ > **Source:** <https://docs.qlty.sh/cli/coding-with-ai-agents.md> (retrieved 2026-08-26).
4
+ > Copied verbatim from the upstream page; only the MDX `<Note>` wrapper was rendered as a
5
+ > Markdown blockquote and relative links were expanded to absolute URLs.
6
+
7
+ ## Use Qlty CLI with AI Coding Agents
8
+
9
+ Qlty CLI gives your AI coding tools a universal "quality gate" for code linting, auto-formatting, and maintainability checks. When you let your coding agent run Qlty as part of its workflow, it can automatically clean up code, catch issues early, and ship changes that pass the same standards you expect from human contributors.
10
+
11
+ ## Requirements
12
+
13
+ * Qlty CLI installed and available on `$PATH`.
14
+ * A Qlty analysis config (`.qlty/qlty.toml`) tailored to your project.
15
+
16
+ ## Compatibility
17
+
18
+ Qlty can be integrated with most AI coding agents that can run shell commands. Popular options include:
19
+
20
+ * Claude Code
21
+ * GitHub Copilot
22
+ * Cursor IDE
23
+ * OpenAI Codex
24
+ * Other agents that can run shell commands
25
+
26
+ > **Note:** Network access must be available from the agent environment.
27
+
28
+ ## Integration methods
29
+
30
+ Because `qlty` is a command-line tool, it can be integrated into your AI agent's workflow in several ways:
31
+
32
+ 1. Project memory/instructions (simplest) -- e.g. `CLAUDE.md`
33
+ 2. Git hooks -- This method works automatically for both humans and agents.
34
+ 3. Agent-specific hooks -- e.g. Claude Code [hooks](https://docs.anthropic.com/en/docs/claude-code/hooks)
35
+
36
+ The `qlty` command is run with CLI arguments and reads code files from the local filesystem. Output is printed to standard out, and exit codes indicate success or failure. This simple interface avoids the need for Model Context Protocol (MCP) server or API integration.
37
+
38
+ ### Project memory integration
39
+
40
+ Each AI Agent offer ways to integrate custom instructions. When coding, agents read these instructions and follow them as part of their workflow. You can add instructions to run the `qlty` command at the right time.
41
+
42
+ The necessary instructions can be as simple as the following:
43
+
44
+ ```md
45
+ - Before committing, ALWAYS run auto-formatting with `qlty fmt`
46
+ - Before finishing, ALWAYS run `qlty check --fix --level=low` and fix any lint errors
47
+ ```
48
+
49
+ You can customize these instructions to fit the particulars of your desired workflow.
50
+
51
+ Each AI coding agent has different paths that it will check for instructions files. Some examples include:
52
+
53
+ * Claude Code: `CLAUDE.md`
54
+ * Cursor: `AGENTS.md`
55
+ * OpenAI Codex: `AGENTS.md`
56
+ * GitHub Copilot: `.github/copilot-instructions.md`
57
+
58
+ Please refer to the documentation of your chosen agent for details on how to add custom instructions.
59
+
60
+ ### Git hooks integration
61
+
62
+ The Qlty CLI can be run through Git hooks to enforce quality gates for both human and AI commits. This method works with any AI agent that can commit code via Git.
63
+
64
+ The typical configuration is to set up a pre-commit hook to run `qlty fmt` and a pre-push hook to run `qlty check`. See [Qlty Git Hooks](https://docs.qlty.sh/cli/git-hooks.md) for more details.
@@ -0,0 +1,291 @@
1
+ # Qlty CLI Command Reference
2
+
3
+ > **Sources** (all retrieved 2026-08-26), one section per upstream page:
4
+ > <https://docs.qlty.sh/cli/commands/init.md>, <https://docs.qlty.sh/cli/commands/check.md>,
5
+ > <https://docs.qlty.sh/cli/commands/fmt.md>, <https://docs.qlty.sh/cli/commands/metrics.md>,
6
+ > <https://docs.qlty.sh/cli/commands/smells.md>, <https://docs.qlty.sh/cli/commands/plugins-list.md>,
7
+ > <https://docs.qlty.sh/cli/commands/plugins-enable.md>.
8
+ > Prose, flag descriptions, and examples are copied from those pages unchanged; the MDX
9
+ > `<AccordionGroup>` / `<Accordion>` option lists are rendered as Markdown bullet lists and the
10
+ > per-example captions are rendered as code-block comments. `initializd` is upstream's typo,
11
+ > preserved. For any flag not listed here, fetch the live page via <https://docs.qlty.sh/llms.txt>.
12
+
13
+ ---
14
+
15
+ ## `init`
16
+
17
+ ```bash
18
+ qlty init [OPTIONS]
19
+ ```
20
+
21
+ Set up Qlty in the current repository
22
+
23
+ This command will generate an initial project configuration file based on the contents of the repository and write it to `.qlty/qlty.toml` at the repository root.
24
+
25
+ When run without the `--skip-plugins` command, initialization will try to determine a reasonable set of linters and formatters to enable. Certain linters and formatters are enabled based on the detection of a linter configuration file. Others are enabled just based on the presence of target files of the programming language.
26
+
27
+ Following initialization, the command will print a summary of the configuration.
28
+
29
+ After generating a configuration file, the command will ask if you want to *sample* the results of the enabled plugins. Sampling runs each plugin against a small set of targets.
30
+
31
+ If Qlty is already initialized in the current repository, this command will exit with an error.
32
+
33
+ ### Arguments
34
+
35
+ * `-y, --yes` — Answer yes to all prompts
36
+ * `-n, --no` — Answer no to all prompts
37
+ * `--skip-plugins` — Skip enabling plugins
38
+ * `--dry-run` — Print the generated configuration to stdout instead of saving to disk
39
+ * `--skip-default-source` — Initialize without default source
40
+ * `--source <SOURCE>` — A custom source to use for plugins. This can be a URL(name=url) or a path to a local directory(name=directory)
41
+
42
+ ### Examples
43
+
44
+ ```bash
45
+ # Generate a Qlty config for the current repository
46
+ qlty init
47
+
48
+ # Generate a Qlty config and skip prompts
49
+ qlty init --no
50
+
51
+ # Generate a Qlty config with no plugins
52
+ qlty init --skip-plugins
53
+ ```
54
+
55
+ ---
56
+
57
+ ## `check`
58
+
59
+ ```bash
60
+ qlty check [OPTIONS] [PATHS]...
61
+ ```
62
+
63
+ Run linters
64
+
65
+ By default, only changed files are analyzed. Use `--all` or specify paths to override this behavior.
66
+
67
+ Installs plugins and their required runtimes as needed before analyzing.
68
+
69
+ By default, issues are cached locally to speed up subsequent runs.
70
+
71
+ Must be run within a Git repository with Qlty initializd.
72
+
73
+ ### Arguments
74
+
75
+ * `[PATHS]...` — Files to analyze
76
+ * `-a, --all` — Check all files, not just changed
77
+ * `--fix` — Apply all auto-fix suggestions automatically. When combined with `--ai`, AI-generated fixes are applied without prompting for review. See [AI Autofixes Security Considerations](https://docs.qlty.sh/cloud/ai-autofixes.md#security-considerations) for important guidance when using this flag.
78
+ * `--no-fix` — Do not apply auto-fix suggestions
79
+ * `--ai` — Generate AI-powered fixes using a large language model (requires Qlty Cloud authentication). AI fixes should be reviewed before applying. Using `--ai` with `--fix` applies AI suggestions automatically without review—see [Security Considerations](https://docs.qlty.sh/cloud/ai-autofixes.md#security-considerations).
80
+ * `--unsafe` — Allow fixes for rules that may produce incorrect results and require careful human review. By default, fixes for certain rules are blocked because they are more likely to need manual judgment. This flag removes those restrictions.
81
+ * `--no-formatters` — Disable formatter checks
82
+ * `--no-progress` — Disable progress bar
83
+ * `--no-fail` — Exit successfully regardless of what issues are found
84
+ * `--no-error` — Exit successfully regardless of linter errors
85
+ * `--sample <SAMPLE>` — Sample results from a number of files for each linter
86
+ * `--level <LEVEL>` — Minimum level of issues to show [default: note] [possible values: note, fmt, low, medium, high]
87
+ * `-j, --jobs <JOBS>` — Maximum number of concurrent jobs
88
+ * `--filter <FILTER>` — Filter by plugin or check
89
+ * `-v, --verbose...` — Print verbose output
90
+ * `--summary` — Print a summary of issues
91
+ * `--upstream <UPSTREAM>` — Upstream base ref to compare against
92
+ * `--no-cache` — Disable caching issues
93
+ * `--print-errors` — Print errors to stderr
94
+ * `--fail-level <FAIL_LEVEL>` — Minimum level of issues to fail on [default: fmt] [possible values: note, fmt, low, medium, high]
95
+ * `--sarif` — SARIF output
96
+
97
+ ### Examples
98
+
99
+ ```bash
100
+ # Run linters on changed files on your current branch
101
+ qlty check
102
+
103
+ # Run linters on all files
104
+ qlty check --all
105
+
106
+ # Run only ESLint on all files
107
+ qlty check --all --filter=eslint
108
+
109
+ # Run linters on the web/ folder
110
+ qlty check web/
111
+ ```
112
+
113
+ ---
114
+
115
+ ## `fmt`
116
+
117
+ ```bash
118
+ qlty fmt [OPTIONS] [PATHS]...
119
+ ```
120
+
121
+ Auto-format files by rewriting them
122
+
123
+ By default, only changed files are auto-formatted. Use `--all` or specify paths to override this behavior.
124
+
125
+ Installs plugins and their required runtimes as needed before analyzing.
126
+
127
+ Must be run within a Git repository with Qlty initializd.
128
+
129
+ ### Arguments
130
+
131
+ * `[PATHS]...` — Files to analyze
132
+ * `-a, --all` — Check all files, not just changed
133
+ * `--no-progress` — Disable progress bar
134
+ * `--no-error` — Exit successfully regardless of linter errors
135
+ * `--sample <SAMPLE>` — Sample results from a number of files for each linter
136
+ * `--jobs <JOBS>` — Maximum number of concurrent jobs
137
+ * `--filter <FILTER>` — Filter by plugin or check
138
+ * `--trigger <TRIGGER>` — [default: manual] [possible values: manual, pre-commit, pre-push, build]
139
+ * `-v, --verbose...` — Print verbose output
140
+ * `--upstream <UPSTREAM>` — Upstream base ref to compare against
141
+ * `--index` — Format files in the Git index
142
+ * `--index-file <INDEX_FILE>` — Format files in the specified Git index file
143
+
144
+ ### Examples
145
+
146
+ ```bash
147
+ # Auto-format changed files on your current branch
148
+ qlty fmt
149
+
150
+ # Auto-format all files with prettier
151
+ qlty fmt --all --filter=prettier
152
+
153
+ # Auto-format files in a directory
154
+ qlty fmt web/
155
+ ```
156
+
157
+ ---
158
+
159
+ ## `metrics`
160
+
161
+ ```bash
162
+ qlty metrics [OPTIONS] [PATHS]...
163
+ ```
164
+
165
+ Compute code quality metrics
166
+
167
+ Calculate metrics like classes count, complexity, lines of code, and cohesion for [supported languages](https://docs.qlty.sh/languages.md) using our custom built static analysis.
168
+
169
+ ### Arguments
170
+
171
+ * `[PATHS]...` — Files to analyze
172
+ * `-a, --all` — Compute metrics for all files, not just changed
173
+ * `-d, --dirs` — Print per-directory stats
174
+ * `--functions` — Print function stats
175
+ * `--max-depth <MAX_DEPTH>` — Directory depth to print, this flag will also set to print per-directory stats
176
+ * `--sort <SORT>` — Sort output by column [possible values: name, classes, functions, fields, lines, loc, complexity, lcom]
177
+ * `--limit <LIMIT>` — Maximum rows to print
178
+ * `--exclude-tests` — Exclude tests
179
+ * `--upstream <UPSTREAM>` — Upstream base ref to compare against
180
+ * `--quiet` — Only show results
181
+
182
+ ### Examples
183
+
184
+ ```bash
185
+ # Summarize metrics across directories
186
+ qlty metrics --all --max-depth 2
187
+
188
+ # Review the 10 most complex files
189
+ qlty metrics --all --sort complexity --limit 10
190
+
191
+ # View function-level metrics for a file
192
+ qlty metrics --functions remix/app/root.tsx
193
+ ```
194
+
195
+ ---
196
+
197
+ ## `smells`
198
+
199
+ ```bash
200
+ qlty smells [OPTIONS] [PATHS]...
201
+ ```
202
+
203
+ Find code smells like duplication and complexity
204
+
205
+ Detect issues like duplication (copy and pasted code), high complexity, deeply nested control flows, etc. for [supported languages](https://docs.qlty.sh/languages.md) using our custom built static analysis.
206
+
207
+ ### Arguments
208
+
209
+ * `[PATHS]...` — Files to analyze
210
+ * `-a, --all` — Compute smells for all files, not just changed
211
+ * `--no-duplication` — Don't check for duplication
212
+ * `--include-tests` — Include tests
213
+ * `--no-snippets` — Don't show code snippets
214
+ * `--upstream <UPSTREAM>` — Upstream base ref to compare against
215
+ * `--quiet` — Only show results
216
+
217
+ ### Examples
218
+
219
+ ```bash
220
+ # Analyze your current branch
221
+ qlty smells
222
+
223
+ # Analyze your entire project for code smells
224
+ qlty smells --all
225
+
226
+ # Analyze specific paths for code smells
227
+ qlty smells example-app/components/ui react-app/utils
228
+
229
+ # Analyze a specific file for code smells
230
+ qlty smells example-app/components/ui/Dropdown.tsx
231
+
232
+ # Skip duplication analysis
233
+ qlty smells --all --no-duplication
234
+
235
+ # Analyze for code smells against a specific upstream branch
236
+ qlty smells --upstream origin/main
237
+ ```
238
+
239
+ ---
240
+
241
+ ## `plugins list`
242
+
243
+ ```bash
244
+ qlty plugins list [OPTIONS]
245
+ ```
246
+
247
+ List all available plugins
248
+
249
+ This command lists all available plugins based on the sources declared in the current project's `qlty.toml` configuration file.
250
+
251
+ ### Examples
252
+
253
+ ```bash
254
+ # List all available plugins
255
+ qlty plugins list
256
+ ```
257
+
258
+ ---
259
+
260
+ ## `plugins enable`
261
+
262
+ ```bash
263
+ qlty plugins enable [OPTIONS] [PLUGINS]...
264
+ ```
265
+
266
+ Enable plugins for the current project
267
+
268
+ The command edits the current project's `qlty.toml` file to enable plugins.
269
+
270
+ ### Arguments
271
+
272
+ * `[PLUGINS]...` — Plugins to enable specified as name=version
273
+
274
+ ### Examples
275
+
276
+ ```bash
277
+ # Enable the latest version of shellcheck
278
+ qlty plugins enable shellcheck
279
+
280
+ # Enable shellcheck version 1.2.3
281
+ qlty plugins enable shellcheck=1.2.3
282
+
283
+ # Enable rubocop and eslint
284
+ qlty plugins enable rubocop eslint
285
+ ```
286
+
287
+ ### See also
288
+
289
+ `qlty plugins upgrade`, `qlty plugins disable` — see
290
+ <https://docs.qlty.sh/cli/commands/plugins-upgrade.md> and
291
+ <https://docs.qlty.sh/cli/commands/plugins-disable.md>.