semgrep

Install command:
brew install semgrep

Easily detect and prevent bugs and anti-patterns in your codebase

https://semgrep.dev

License: LGPL-2.1-only

Development: Pull requests

Formula JSON API: /api/formula/semgrep.json

Formula code: semgrep.rb on GitHub

Bottle (binary package) installation support provided for:

macOS on
Apple Silicon
tahoe
sequoia
sonoma
macOS on
Intel
sonoma
Linux ARM64
x86_64

Current versions:

stable 1.156.0
head ⚡️ HEAD

Depends on:

certifi 2026.2.25 Mozilla CA bundle for Python
cryptography 46.0.5 Cryptographic recipes and primitives for Python
dwarfutils 2.3.1 Dump and produce DWARF debug information in ELF objects
gmp 6.3.0 GNU multiple precision arithmetic library
libev 4.33 Asynchronous event library
pcre2 10.47 Perl compatible regular expressions library with a new API
pydantic 2.12.5 Data validation using Python type hints
python@3.14 3.14.3 Interpreted, interactive, object-oriented programming language
rpds-py 0.30.0 Python bindings to Rust's persistent data structures
sqlite 3.51.3 Command-line interface for SQLite
tree-sitter 0.26.7 Incremental parsing library
zstd 1.5.7 Zstandard is a real-time compression algorithm

Depends on when building from source:

ocaml 5.4.0 General purpose programming language in the ML family
opam 2.5.0 OCaml package manager
pkgconf 2.5.1 Package compiler and linker metadata toolkit

Analytics:

Installs (30 days)
semgrep 8,178
semgrep --HEAD 10
Installs on Request (30 days)
semgrep 8,175
semgrep --HEAD 10
Build Errors (30 days)
semgrep 1
Installs (90 days)
semgrep 22,177
semgrep --HEAD 25
Installs on Request (90 days)
semgrep 22,157
semgrep --HEAD 25
Installs (365 days)
semgrep 63,355
semgrep --HEAD 88
Installs on Request (365 days)
semgrep 63,302
semgrep --HEAD 88