diff --git a/CHANGELOG.md b/CHANGELOG.md index 061b0dd0..2870e266 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,12 @@ ## On the `main` branch +### Fixes + +- When running `semgrep`, its always added to `PATH`, + as otherwise semgrep is not able to find `pysemgrep` folder. + ([#439](https://github.com/crashappsec/chalk/pull/439)) + ## 0.4.13 **Oct 10, 2024** diff --git a/src/configs/sastconfig.c4m b/src/configs/sastconfig.c4m index f0ec3172..365877bc 100644 --- a/src/configs/sastconfig.c4m +++ b/src/configs/sastconfig.c4m @@ -93,6 +93,10 @@ func semgrep_system() { trace("find_semgrep: Unable to find semgrep in $PATH") } else { trace("find_semgrep: found semgrep in $PATH: " + result) + # ensure semgrep is on PATH + # https://github.com/semgrep/semgrep/issues/10652 + head, tail := path_split(result) + result := "PATH=" + head + ":$PATH " + result } }