Skip to content

Commit 5bb6d5a

Browse files
authored
Fix actions/checkout@v2 (#1472)
# Changes Using `actions/checkout@v2` to checkout the github code onto your local workspace is nice, but can be problematic when using old docker image. From what I understand, the action uses NodeJS version internally and therefore requires a modern glibc version as the action can impose newer NodeJS version and therefore can eventually break our build. To avoid this, I'm just going to manually checkout the code and run the submodule update manually. This will fix our C builds.
1 parent d56864f commit 5bb6d5a

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

.github/workflows/c.yaml

+8-6
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,6 @@ jobs:
3131

3232
runs-on: ubuntu-latest
3333
container: ubuntu:18.04
34-
env:
35-
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true
3634

3735
steps:
3836

@@ -47,10 +45,14 @@ jobs:
4745
apt-get -qq update
4846
apt-get -qq install libeigen3-dev libserialport-dev git cmake build-essential ${{ matrix.compiler.package }}
4947
50-
- uses: actions/checkout@v2
51-
with:
52-
submodules: recursive
53-
fetch-depth: 0
48+
- name: Checkout
49+
run: |
50+
git config --global --add safe.directory "${PWD}"
51+
git init
52+
git remote add origin "https://github.com/${{ github.repository }}"
53+
git fetch --no-tags --depth=1 origin "${{ github.sha }}"
54+
git checkout "${{ github.sha }}"
55+
git submodule update --recursive --init --depth=1
5456
5557
- name: Configure
5658
run: |

0 commit comments

Comments
 (0)