From 588b84aa898b86a51dd726460ad923ca8dc7d16e Mon Sep 17 00:00:00 2001 From: William Rusnack Date: Fri, 12 Jul 2024 17:15:29 -0400 Subject: [PATCH] ci now checks for changes in source\nuseful for changing checking to ensure that package.yaml and *.cabal are synced --- .github/workflows/tests.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 94cff15b..d29141af 100755 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -68,6 +68,17 @@ jobs: ghc --version stack --version stack test --system-ghc $extraLibDirs $extraIncludeDirsLLVM $extraIncludeDirsFFI --fast --no-terminal --snapshot=lts-$snapshot + - name: Check for Source Changes + shell: bash + run: | + if [ -n "$(git status --porcelain)" ] + then + >&2 echo 'ERROR: Source Changed After Build' + >&2 git diff + >&2 git status + >&2 echo 'ERROR: Source Changed After Build' + exit 1 + fi Cabal: name: Cabal