AptLynx

Command-line tool

ast-grep

brew/ast-grep

Checked 25 Oct 2026, 21:09 UTC · Listing refreshed from Homebrew, winget, npm, Scoop and cargo; npm packages checked against OSV.dev

Code searching, linting, rewriting rust typescript search command-line static-analysis grep tree-sitter command-line-tool linter ast refactoring babel

At a glance

Type
Command-line tool
Install on
Windows, macOS, Linux
Last checked
25 Oct 2026, 21:09 UTC

Install it

Windows

winget install --id ast-grep.ast-grep -e
scoop install ast-grep
cargo install ast-grep

macOS

brew install ast-grep
cargo install ast-grep

Linux

brew install ast-grep
cargo install ast-grep

Search for a pattern in files

ast-grep run -p 'pattern' path/to/file

Search for a pattern in a specific language

ast-grep run -p 'pattern' -l python path/to/directory

Rewrite code matching a pattern

ast-grep run -p 'pattern' -r 'replacement' path/to/file

Browse

Related command-line tools

Listing text is written by the maker; AptLynx lists tools and does not vouch for them. Find another tool · Browse by topic · For agents