Skip to content
Snippets Groups Projects
Commit 3e1661a1 authored by Massimiliano Culpo's avatar Massimiliano Culpo Committed by Peter Scheibel
Browse files

Use "fetch-depth: 0" to retrieve all history from remote

parent c4f29c63
No related branches found
No related tags found
No related merge requests found
...@@ -19,6 +19,8 @@ jobs: ...@@ -19,6 +19,8 @@ jobs:
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: ${{ matrix.python-version }} python-version: ${{ matrix.python-version }}
...@@ -35,9 +37,7 @@ jobs: ...@@ -35,9 +37,7 @@ jobs:
run: | run: |
# Need this for the git tests to succeed. # Need this for the git tests to succeed.
git --version git --version
git config --global user.email "spack@example.com" . .github/workflows/setup_git.sh
git config --global user.name "Test User"
git fetch -u origin develop:develop
- name: Install kcov for bash script coverage - name: Install kcov for bash script coverage
env: env:
KCOV_VERSION: 34 KCOV_VERSION: 34
...@@ -62,6 +62,8 @@ jobs: ...@@ -62,6 +62,8 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.8 python-version: 3.8
...@@ -78,9 +80,7 @@ jobs: ...@@ -78,9 +80,7 @@ jobs:
run: | run: |
# Need this for the git tests to succeed. # Need this for the git tests to succeed.
git --version git --version
git config --global user.email "spack@example.com" . .github/workflows/setup_git.sh
git config --global user.name "Test User"
git fetch -u origin develop:develop
- name: Install kcov for bash script coverage - name: Install kcov for bash script coverage
env: env:
KCOV_VERSION: 38 KCOV_VERSION: 38
......
...@@ -14,6 +14,8 @@ jobs: ...@@ -14,6 +14,8 @@ jobs:
runs-on: macos-latest runs-on: macos-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.7 python-version: 3.7
...@@ -30,7 +32,7 @@ jobs: ...@@ -30,7 +32,7 @@ jobs:
- name: Run unit tests - name: Run unit tests
run: | run: |
git --version git --version
git fetch -u origin develop:develop . .github/workflows/setup_git.sh
. share/spack/setup-env.sh . share/spack/setup-env.sh
coverage run $(which spack) test coverage run $(which spack) test
coverage combine coverage combine
......
#!/usr/bin/env sh
git config --global user.email "spack@example.com"
git config --global user.name "Test User"
# With fetch-depth: 0 we have a remote develop
# but not a local branch. Don't do this on develop
if [ "$(git branch --show-current)" != "develop" ]
then
git branch develop origin/develop
fi
...@@ -41,9 +41,7 @@ jobs: ...@@ -41,9 +41,7 @@ jobs:
run: | run: |
# Need this for the git tests to succeed. # Need this for the git tests to succeed.
git --version git --version
git config --global user.email "spack@example.com" . .github/workflows/setup_git.sh
git config --global user.name "Test User"
git fetch -u origin develop:develop
- name: Run flake8 tests - name: Run flake8 tests
run: | run: |
share/spack/qa/run-flake8-tests share/spack/qa/run-flake8-tests
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment