diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index c764dfbf..69c5d74d 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -15,16 +15,11 @@ jobs: runs-on: ubuntu-latest container: { image: 'ghcr.io/tim-janik/anklang-ci:focal-latest' } steps: - - run: | - sudo chown -R `id -u`:`id -g` . ~ ;# /github/home - actions/runner/issues/863 - export HOME=$(env -i bash -c 'echo ~') && echo HOME=$HOME | sudo tee -a $GITHUB_ENV - ! [[ $RUNNER_TEMP =~ _ ]] || sudo chmod -R 0777 $RUNNER_TEMP ;# for GH action cache - - name: 'Git Checkout' - run: | - git --version && git clone -q --recurse-submodules https://github.com/$GITHUB_REPOSITORY . - git fetch origin $GITHUB_REF # e.g. refs/pull/nnn/merge - [[ $GITHUB_REF =~ ^refs/heads/ ]] && BRANCHORSHA=$GITHUB_REF_NAME || BRANCHORSHA=$GITHUB_SHA - git checkout -q $BRANCHORSHA && git describe --always + - { uses: actions/checkout@v4.1.1, with: { fetch-depth: 0, submodules: recursive } } + - name: 'Fetch all tags' + run: | + sed 's,git@github.com:,https://github.com/,' -i .git/config ; # fetch without ssh creds + git fetch -f --tags && git describe --always --long ; # Fix actions/checkout#290 - name: 'Configure build presets' run: | echo -e ' prefix=/\n CC=clang \n CXX=clang++ \n CLANG_TIDY=clang-tidy ' > config-defaults.mk @@ -41,9 +36,11 @@ jobs: runs-on: ubuntu-latest container: { image: 'ghcr.io/tim-janik/anklang-ci:focal-latest' } steps: - - run: id && pwd && env && ls -al - - { uses: actions/checkout@v4.1.1, with: { fetch-depth: 0 } } # Fix actions/checkout#290 - - run: git fetch -f --tags && git submodule update --init --recursive && git describe + - { uses: actions/checkout@v4.1.1, with: { fetch-depth: 0, submodules: recursive } } + - name: 'Fetch all tags' + run: | + sed 's,git@github.com:,https://github.com/,' -i .git/config ; # fetch without ssh creds + git fetch -f --tags && git describe --always --long ; # Fix actions/checkout#290 - name: 'Configure build presets' run: | echo -e ' prefix=/\n CC=clang \n CXX=clang++ \n CLANG_TIDY=clang-tidy ' > config-defaults.mk @@ -57,9 +54,11 @@ jobs: runs-on: ubuntu-latest container: { image: 'ghcr.io/tim-janik/anklang-ci:arch-latest' } steps: - - run: id && pwd && env && ls -al - - { uses: actions/checkout@v4.1.1, with: { fetch-depth: 0 } } # Fix actions/checkout#290 - - run: git fetch -f --tags && git submodule update --init --recursive && git describe + - { uses: actions/checkout@v4.1.1, with: { fetch-depth: 0, submodules: recursive } } + - name: 'Fetch all tags' + run: | + sed 's,git@github.com:,https://github.com/,' -i .git/config ; # fetch without ssh creds + git fetch -f --tags && git describe --always --long ; # Fix actions/checkout#290 - name: 'Configure build presets' run: | echo 'prefix=/' > config-defaults.mk ;# reset any previous config-defaults.mk @@ -82,9 +81,11 @@ jobs: runs-on: ubuntu-latest container: { image: 'ghcr.io/tim-janik/anklang-ci:focal-latest' } steps: - - run: id && pwd && env && ls -al - - { uses: actions/checkout@v4.1.1, with: { fetch-depth: 0 } } # Fix actions/checkout#290 - - run: git fetch -f --tags && git submodule update --init --recursive && git describe + - { uses: actions/checkout@v4.1.1, with: { fetch-depth: 0, submodules: recursive } } + - name: 'Fetch all tags' + run: | + sed 's,git@github.com:,https://github.com/,' -i .git/config ; # fetch without ssh creds + git fetch -f --tags && git describe --always --long ; # Fix actions/checkout#290 - name: 'Configure build presets' run: | echo -e ' prefix=/\n CC=clang \n CXX=clang++ \n CLANG_TIDY=clang-tidy ' > config-defaults.mk