Skip to content

Commit

Permalink
Check submodule hash consistency (#229)
Browse files Browse the repository at this point in the history
* check-cleanliness CI test

* Oops, forgot to update gitmodules. (DUPLICATION IS EVIL)

* call git-fleximod update before git diff check

* Revert: Oops, forgot to update gitmodules. (DUPLICATION IS EVIL)

* switch to git-fleximod test for hash consistency checking

* update MOM6 submodule but forget to update gitmodules. This should result in CI failure

* revert MOM6 submodule. This should fix in CI failure
  • Loading branch information
alperaltuntas authored Feb 10, 2025
1 parent 7d94ab5 commit 84cfd0b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/general-ci-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,21 @@ jobs:
cd $GITHUB_WORKSPACE/CESM/components/mom/
git fetch origin pull/${{ github.event.pull_request.number }}/head:pr-${{ github.event.pull_request.number }}
git checkout pr-${{ github.event.pull_request.number }}
git submodule update --init --recursive
- name: Checkout initial event (Push)
if: ${{ github.event_name == 'push' }}
run: |
echo "Handling push"
cd $GITHUB_WORKSPACE/CESM/components/mom/
git checkout ${{ github.sha }}
git submodule update --init --recursive
- name: Check submodule hash consistency
run: |
echo "Checking if .gitmodules and external hashes are consistent"
cd $GITHUB_WORKSPACE/CESM/components/mom/
../../bin/git-fleximod test
# Build the standalone mom using the ubuntu script.
- name: Build Standalone MOM
Expand Down

0 comments on commit 84cfd0b

Please sign in to comment.