commit | 556106ac3b922aa468a5524b928b0d8ee5cde473 | [log] [tgz] |
---|---|---|
author | Oliver Newman <olivernewman@google.com> | Wed Sep 20 16:32:11 2023 +0000 |
committer | CQ Bot <fuchsia-internal-scoped@luci-project-accounts.iam.gserviceaccount.com> | Wed Sep 20 16:32:11 2023 +0000 |
tree | 5f66f44cd84af5047bcb41c01e8b8a8871493f72 | |
parent | 052c1e42bcd92b9b44567ab7d927d48ab04ae2b4 [diff] |
[cli] Let users override entry point file name Some checks may require special permissions, or users may not want to run them by default for some other reason. This allows such checks to be written and registered in a separate Starlark file that can be run using `shac check --entrypoint <filename>`. Also change `main` terminology to `entrypoint` throughout the codebase for consistency and clarity; `main` doesn't make it clear that the value is the name of the Starlark file being run. Bug: 130779 Change-Id: I92d962d7faba5830b791e0096f265539d9608d81 Reviewed-on: https://fuchsia-review.googlesource.com/c/shac-project/shac/+/919372 Reviewed-by: Anthony Fandrianto <atyfto@google.com> Commit-Queue: Auto-Submit <auto-submit@fuchsia-infra.iam.gserviceaccount.com> Fuchsia-Auto-Submit: Oliver Newman <olivernewman@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.