Semgrep Plugin for IntelliJ-based IDEs communicates with Semgrep command-line interface (CLI) to run scans. Install Semgrep CLI before you can use the IntelliJ Plugin. To install Semgrep CLI:
# For macOS
$ brew install semgrep
# For Ubuntu/WSL/Linux/macOS
$ python3 -m pip install semgrep
# To try Semgrep without installation run via Docker
$ docker run --rm -v "${PWD}:/src" returntocorp/semgrep semgrep
-
Using the IDE built-in plugin system:
Settings/Preferences > Plugins > Marketplace > Search for " semgrep-intellij" > Install
-
Manually:
Download the latest release and install it manually using Settings/Preferences > Plugins > ⚙️ > Install plugin from disk...
Try Autofix.
Add and update new rules to expand Semgrep extension capabilities.
You can fine-tune and customize rules to improve your scan results:
- Go to Semgrep Registry. Ensure that you are signed in.
- Explore the Semgrep Registry, select a rule, and then click Add to Rule Board.
- Manage rules in the Policies page.
Semgrep supports 30+ languages.
Category | Languages |
---|---|
GA | C# · Go · Java · JavaScript · JSX · Kotlin · JSON · PHP · Python · Ruby · Scala · Terraform · TypeScript |
Beta | Rust |
Experimental | Bash · C · C++ · Clojure · Dart · Dockerfile · Elixir · HTML · Julia · Jsonnet · Lisp · Lua · OCaml · R · Scheme · Solidity · Swift · YAML · XML · Generic (ERB, Jinja, etc.) |
If you need our support, join the Semgrep community Slack workspace and tell us about any problems you encountered.