Skip to content

Commit aea7995

Browse files
authored
ci: ignore mise.lock drift in release build (#2964)
1 parent 20b6ecb commit aea7995

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

.github/workflows/release-build.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,6 +220,25 @@ jobs:
220220
with:
221221
cache_key_prefix: mise-rel-${{ github.job }}
222222

223+
- name: Keep release tree clean after mise
224+
run: |
225+
CHANGED_FILES=$(git status --porcelain)
226+
if [ -z "$CHANGED_FILES" ]; then
227+
echo "Working tree is clean"
228+
exit 0
229+
fi
230+
231+
NON_MISE_CHANGES=$(git status --porcelain | grep -vE "^[[:space:]]*[MARCDU?!]{1,2}[[:space:]]+mise\.lock$" || true)
232+
if [ -n "$NON_MISE_CHANGES" ]; then
233+
echo "::error::Unexpected file changes after tool setup"
234+
git status --short
235+
exit 1
236+
fi
237+
238+
echo "Resetting mise.lock changes introduced during setup"
239+
git checkout -- mise.lock
240+
git status --short
241+
223242
- name: Check for existing release
224243
run: |
225244
TAG="${{ github.ref_name }}"

0 commit comments

Comments
 (0)