From 1500a7c699bd14ecd5cf4795c08a05183e30d104 Mon Sep 17 00:00:00 2001 From: Ruhan Date: Wed, 18 Sep 2024 16:03:12 +0530 Subject: [PATCH] feat: semgrep --- docs/tools/semgrep.md | 62 +++++++++++++++++++++++++++++++++++++++++++ docs/tools/tools.md | 2 ++ 2 files changed, 64 insertions(+) create mode 100644 docs/tools/semgrep.md diff --git a/docs/tools/semgrep.md b/docs/tools/semgrep.md new file mode 100644 index 00000000..7aca24ab --- /dev/null +++ b/docs/tools/semgrep.md @@ -0,0 +1,62 @@ +--- +title: Semgrep +sidebar_label: Semgrep +description: CodeRabbit's guide to Semgrep. +--- + +[Semgrep](https://semgrep.dev/) is a static analysis tool designed to scan code for security vulnerabilities and code quality issues.. + +## Files + +Semgrep will run on the following files and extensions: + +- `Apex` +- `Bash` +- `.c` +- `.cpp` +- `.cs` +- `.clj` +- `.dart` +- `Dockerfile` +- `.ex` +- `.html` +- `.go` +- `.java` +- `.js` +- `.jsx` +- `.json` +- `.jl` +- `.jsonnet` +- `.kt` +- `.kts` +- `Lisp` +- `.lua` +- `.ml` +- `.php` +- `.py` +- `.r` +- `.rb` +- `.rs` +- `.scala` +- `Scheme` +- `.sol` +- `.swift` +- `.tf` +- `.ts` +- `.tsx` +- `.yaml` +- `.xml` +- `ERB` +- `Jinja` + +## Configuration + +Semgrep uses a YAML style configuration file. + +Semgrep supports the following config files: + +- User-defined config file set at `reviews.tools.semgrep.config_file` in your project's `.coderabbit.yaml` file or setting the "Review → Tools → Semgrep → Config File" field in CodeRabbit's settings page. + +## Links + +- [Semgrep Cli Reference](https://semgrep.dev/docs/cli-reference) diff --git a/docs/tools/tools.md b/docs/tools/tools.md index f7f453cd..081258db 100644 --- a/docs/tools/tools.md +++ b/docs/tools/tools.md @@ -60,6 +60,7 @@ Remove extraneous f prefix | Python | [Ruff][Ruff] | | Regal | [Regal][Regal] | | Ruby | [Rubocop][Rubocop] | +| Semgrep | [Semgrep][Semgrep] | | Shell (sh, bash, ksh, dash) | [ShellCheck][ShellCheck] | | Swift | [SwiftLint][SwiftLint] | | Terraform | [Checkov][Checkov] | @@ -87,4 +88,5 @@ Remove extraneous f prefix [PMD]: ./pmd.md [Cppcheck]: ./cppcheck.md [CircleCi]: ./circleci.md +[Semgrep]: ./semgrep.md