.github: use new checkout v4 option "filter: tree:0"

This saves time without affecting git describe like fetch depth does.

Also cancel fetch depth when building the firmware.

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
This commit is contained in:
Marc Herbert 2024-01-25 16:51:28 -08:00 committed by Kai Vehmanen
parent da2b026c76
commit 46eb79eb45
10 changed files with 22 additions and 8 deletions

View File

@ -48,6 +48,7 @@ jobs:
- uses: actions/checkout@v4
with:
path: ./workspace/sof
filter: 'tree:0'
- name: west update
run: |

View File

@ -57,6 +57,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
filter: 'tree:0'
- name: run yamllint
# Quoting to please all parsers is hard. This indirection helps.

View File

@ -28,8 +28,7 @@ jobs:
steps:
- uses: actions/checkout@v4
# From time to time this will catch a git tag and change SOF_VERSION
with: {fetch-depth: 50, submodules: recursive}
with: {fetch-depth: 0, submodules: recursive, filter: 'tree:0'}
- name: docker
run: docker pull thesofproject/sof && docker tag thesofproject/sof sof

View File

@ -63,6 +63,7 @@ jobs:
- uses: actions/checkout@v4
with:
path: ./workspace/sof
filter: 'tree:0'
- name: west update
run: |

View File

@ -38,6 +38,8 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
filter: 'tree:0'
- name: apt get doxygen graphviz
run: sudo apt-get -y install ninja-build doxygen graphviz
@ -72,6 +74,8 @@ jobs:
steps:
- uses: actions/checkout@v4
with:
filter: 'tree:0'
- name: apt-get update
run: sudo apt-get update
@ -107,7 +111,7 @@ jobs:
steps:
- uses: actions/checkout@v4
with: {fetch-depth: 5, submodules: recursive}
with: {fetch-depth: 0, submodules: recursive, filter: 'tree:0'}
- name: docker
run: docker pull thesofproject/sof && docker tag thesofproject/sof sof
@ -134,7 +138,7 @@ jobs:
steps:
- uses: actions/checkout@v4
with: {fetch-depth: 0, submodules: recursive}
with: {fetch-depth: 0, submodules: recursive, filter: 'tree:0'}
- name: docker
run: docker pull thesofproject/sof && docker tag thesofproject/sof sof
@ -169,7 +173,7 @@ jobs:
steps:
- uses: actions/checkout@v4
with: {fetch-depth: 0, submodules: recursive}
with: {fetch-depth: 0, submodules: recursive, filter: 'tree:0'}
- name: turn off HAVE_AGENT
run: echo CONFIG_HAVE_AGENT=n >

View File

@ -20,7 +20,7 @@ jobs:
steps:
- uses: actions/checkout@v4
with: {fetch-depth: 5, submodules: recursive}
with: {fetch-depth: 0, submodules: recursive, filter: 'tree:0'}
- name: docker pull
run: docker pull thesofproject/sof && docker tag thesofproject/sof sof

View File

@ -35,7 +35,7 @@ jobs:
steps:
- uses: actions/checkout@v4
with: {fetch-depth: 5}
with: {fetch-depth: 0, filter: 'tree:0'}
- name: apt get
run: sudo apt-get update &&

View File

@ -13,6 +13,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
filter: 'tree:0'
# The ALSA version in Ubuntu 20.04 is buggy
# (https://github.com/thesofproject/sof/issues/2543) and likely

View File

@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with: {fetch-depth: 2}
with: {fetch-depth: 2, filter: 'tree:0'}
- name: build and run all defconfigs
run: ./test/test-all-defconfigs.sh

View File

@ -22,6 +22,7 @@ jobs:
- uses: actions/checkout@v4
with:
path: ./workspace/sof
filter: 'tree:0'
- name: plain west update
run: |
@ -70,6 +71,7 @@ jobs:
- uses: actions/checkout@v4
with:
path: ./workspace/sof
filter: 'tree:0'
- name: west clones
run: pip3 install west && cd workspace/sof/ && west init -l &&
@ -128,6 +130,7 @@ jobs:
# This is especially useful for daily builds (but not just).
with:
fetch-depth: 0
filter: 'tree:0'
path: ./workspace/sof
- name: west clones
@ -227,6 +230,7 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0
filter: 'tree:0'
path: ./workspace/sof
# Cache artifacts so we do not overload external servers with downloads
@ -381,6 +385,7 @@ jobs:
# Isolate the clone in a subdirectory to make sure globbing
# does not catch random SOF files.
path: ./sof
filter: 'tree:0'
- name: Download Windows and Linux builds
uses: actions/download-artifact@v3