Maintainers
Pricing
Enterprise
More
More
Documentation
Try Live
Rankings
Install
Blog
Docs7
Ask
New
Add Docs
SonarQube Documentation
https://docs.sonarsource.com/
Admin
Documentation for SonarQube Server, SonarQube Cloud, and SonarQube for IDE.
Tokens:
2,343,892
Snippets:
15,423
Trust Score:
10
Update:
1 day ago
Context
Chat
Benchmark
68.76
Latest
Show doc for...
Code
Info
Show Results
Tokens:
Raw
Copy
Link
Tokens:
Raw
Copy
Link
### Run guided integration skill Source: https://docs.sonarsource.com/agent-centric-development-cycle/developer-tools/agent-plugins/github-copilot-cli.md After installing the plugin, run this command to start the guided integration skill. It installs the SonarQube CLI, authenticates, and runs 'sonar integrate copilot' to set up components. ```bash /sonar-integrate ``` -------------------------------- ### Run SonarQube guided integration skill Source: https://docs.sonarsource.com/agent-centric-development-cycle/developer-tools/agent-plugins/codex-cli.md Starts the guided integration skill that installs the SonarQube CLI, authenticates with SonarQube, and runs 'sonar integrate codex' to set up hooks and the MCP server. ```text $sonar-integrate ``` -------------------------------- ### Run SonarQube Integration Skill Source: https://docs.sonarsource.com/agent-centric-development-cycle/developer-tools/agent-plugins/antigravity.md Starts the guided integration skill that installs the CLI, authenticates, and runs 'sonar integrate antigravity'. Note that --project and --global are mutually exclusive. ```text /sonarqube:sonar-integrate ``` -------------------------------- ### Typical first run with SonarQube CLI Source: https://docs.sonarsource.com/sonarqube-cli/readme.md Shows a typical first-run session: installing via Homebrew or Mise, authenticating with 'sonar auth login', analyzing a file for secrets, listing issues, and analyzing staged changes. Requires a user token and a supported OS. ```bash # Install (see the quickstart for Homebrew, Mise, and Windows) brew install sonarqube-cli # or: mise use -g sonarqube-cli@latest # Install script: curl -o- https://raw.githubusercontent.com/SonarSource/sonarqube-cli/refs/heads/master/user-scripts/install.sh | bash # Authenticate (opens your browser) sonar auth login # Find a secret in a file sonar analyze secrets src/config.ts # List open issues (project key is auto-detected) sonar list issues --format table # Analyze your staged changes against SonarQube Cloud sonar analyze --staged ``` -------------------------------- ### Append sonar integrate to existing setup script Source: https://docs.sonarsource.com/sonarqube-cli/integrations/conductor.md If your repository already has a setup script, append the integration command to the existing setup flow. This example shows appending after `npm install`. ```bash npm install && sonar integrate <codex|claude|cursor> --non-interactive ``` -------------------------------- ### sonar context help and init examples Source: https://docs.sonarsource.com/sonarqube-cli/using-sonarqube-cli/commands.md Example invocations of the sonar context command: 'sonar context help' and 'sonar context init'. These forward the action and arguments to the sonar-context-augmentation binary. ```bash sonar context help sonar context init ```