commit | f429c077682e89c221f876797abb0b439b813519 | [log] [tgz] |
---|---|---|
author | Oliver Newman <olivernewman@google.com> | Fri Aug 04 23:19:38 2023 +0000 |
committer | CQ Bot <fuchsia-internal-scoped@luci-project-accounts.iam.gserviceaccount.com> | Fri Aug 04 23:19:38 2023 +0000 |
tree | aab355630214867c937cb4bcaa3185782dd9f2c5 | |
parent | 99394d7bec91cb700a693b901c2807722db117ea [diff] |
[scm] Handle warnings in git diff output The `git diff` output can sometimes include non-fatal warning messages at the end. For example, if the diff contains at least `diff.renameLimit` files, the following messages will show up (newline-separated, even with the `-z` flag) at the end of the stdout: warning: exhaustive rename detection was skipped due to too many files. warning: you may want to set your diff.renameLimit variable to at least 2458 and retry the command. We should ignore these messages as long as `git diff` produces a retcode of zero, rather than erroring out. Change-Id: I59fa60a36fa8bc76d7f517332588667bea171f8b Reviewed-on: https://fuchsia-review.googlesource.com/c/shac-project/shac/+/892540 Fuchsia-Auto-Submit: Oliver Newman <olivernewman@google.com> Commit-Queue: Auto-Submit <auto-submit@fuchsia-infra.iam.gserviceaccount.com> Reviewed-by: Marc-Antoine Ruel <maruel@google.com>
Shac (Scalable Hermetic Analysis and Checks) is a unified and ergonomic tool and framework for writing and running static analysis checks.
Shac checks are written in Starlark.
go install go.fuchsia.dev/shac-project/shac@latest shac check shac doc shac.star | less
Planned features/changes, in descending order by priority:
shac.textproto
shac.star
files.shac
cache directory that checks can write toctx.scm
glob
arguments to ctx.scm.{all,affected}_files()
functions for easier filtering⚠ The source of truth is at https://fuchsia.googlesource.com/shac-project/shac.git and uses Gerrit for code review.
See CONTRIBUTING.md to submit changes.