Skip to content

Commit

Permalink
Check that all dependencies are pinned in extern/CMakeLists.txt.
Browse files Browse the repository at this point in the history
  • Loading branch information
LTLA committed Oct 14, 2024
1 parent f2f387d commit 4de4bcb
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/run-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,26 @@ jobs:
if: steps.wasm-build.outputs.cache-hit != 'true'
run: bash build.sh main

- name: Check all transitive dependencies are pinned
if: steps.wasm-build.outputs.cache-hit != 'true'
shell: /bin/bash -e {0}
run: |
cat extern/CMakeLists.txt | \
grep "FetchContent_MakeAvailable" | \
sed "s/FetchContent_MakeAvailable(//" | \
sed "s/)//" | \
tr '[:upper:]' '[:lower:]' | \
sort > requested.txt
ls build_main/_deps/ | \
grep "src$" | \
sed "s/-src//" | \
sort > observed.txt
diffs=$(diff observed.txt requested.txt )
if [[ $diffs != '' ]]
then
exit 1
fi
- name: Run tests
run: |
export CHECK_RDS=1
Expand Down
1 change: 1 addition & 0 deletions extern/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ FetchContent_Declare(
GIT_TAG v1.1.0
)

FetchContent_MakeAvailable(aarand)
FetchContent_MakeAvailable(subpar)

FetchContent_MakeAvailable(tatami)
Expand Down

0 comments on commit 4de4bcb

Please sign in to comment.