From 7a9bf838c5aa3a187cfb663235963cb35da5a3cf Mon Sep 17 00:00:00 2001 From: Manabu McCloskey Date: Wed, 9 Oct 2024 10:31:27 -0700 Subject: [PATCH] fail pr action if git is in ditry state (#400) Signed-off-by: Manabu McCloskey --- .github/workflows/pr.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index 9b9b4752..c470b4d4 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -16,4 +16,9 @@ jobs: - name: Run tests run: | make build + if [[ -n $(git status --porcelain) ]]; then + echo "git is in dirty state"; + git status --porcelain=2 --branch + exit 1 + fi make test