mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-04-14 10:07:39 +08:00
ci(workflows): shallow checkout and fail-fast in checks
Port checkout hygiene from the CI orchestrator branch (mrpollo/ci_orchestration) to current workflows without merging the orchestrator itself. - checks.yml: enable fail-fast (99% success rate observed, cancel on first failure saves runner time), switch to fetch-depth 1, extract safe.directory to its own step - itcm_check.yml: fetch-depth 1, drop submodules: recursive (the Makefile bootstraps submodules as a prerequisite of board targets) - sitl_tests.yml, ros_integration_tests.yml, mavros_mission_tests.yml, mavros_offboard_tests.yml, python_checks.yml: fetch-depth 1 Each change matches the corresponding job in ci-orchestrator.yml on mrpollo/ci_orchestration 1:1. Workflows that legitimately need history (clang-tidy, flash_analysis, failsafe_sim, ros_translation_node, ekf_*_change_indicator, build_all_targets) are left alone. Signed-off-by: Ramon Roche <mrpollo@gmail.com>
This commit is contained in:
parent
100d9c97fb
commit
8552465408
8
.github/workflows/checks.yml
vendored
8
.github/workflows/checks.yml
vendored
@ -24,7 +24,7 @@ jobs:
|
|||||||
image: ghcr.io/px4/px4-dev:v1.17.0-rc2
|
image: ghcr.io/px4/px4-dev:v1.17.0-rc2
|
||||||
|
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: true
|
||||||
matrix:
|
matrix:
|
||||||
check: [
|
check: [
|
||||||
"check_format",
|
"check_format",
|
||||||
@ -43,14 +43,16 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 1
|
||||||
|
|
||||||
|
- name: Configure Git Safe Directory
|
||||||
|
run: git config --system --add safe.directory '*'
|
||||||
|
|
||||||
- name: Building [${{ matrix.check }}]
|
- name: Building [${{ matrix.check }}]
|
||||||
env:
|
env:
|
||||||
PX4_SBOM_DISABLE: 1
|
PX4_SBOM_DISABLE: 1
|
||||||
run: |
|
run: |
|
||||||
cd "$GITHUB_WORKSPACE"
|
cd "$GITHUB_WORKSPACE"
|
||||||
git config --system --add safe.directory '*'
|
|
||||||
make ${{ matrix.check }}
|
make ${{ matrix.check }}
|
||||||
|
|
||||||
- name: Uploading Coverage to Codecov.io
|
- name: Uploading Coverage to Codecov.io
|
||||||
|
|||||||
3
.github/workflows/itcm_check.yml
vendored
3
.github/workflows/itcm_check.yml
vendored
@ -48,8 +48,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 1
|
||||||
submodules: recursive
|
|
||||||
|
|
||||||
- name: Git ownership workaround
|
- name: Git ownership workaround
|
||||||
run: git config --system --add safe.directory '*'
|
run: git config --system --add safe.directory '*'
|
||||||
|
|||||||
2
.github/workflows/mavros_mission_tests.yml
vendored
2
.github/workflows/mavros_mission_tests.yml
vendored
@ -26,7 +26,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 1
|
||||||
|
|
||||||
- name: Build SITL and Run Tests (inside old ROS container)
|
- name: Build SITL and Run Tests (inside old ROS container)
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
2
.github/workflows/mavros_offboard_tests.yml
vendored
2
.github/workflows/mavros_offboard_tests.yml
vendored
@ -26,7 +26,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 1
|
||||||
|
|
||||||
- name: Build SITL and Run Tests (inside old ROS container)
|
- name: Build SITL and Run Tests (inside old ROS container)
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
2
.github/workflows/python_checks.yml
vendored
2
.github/workflows/python_checks.yml
vendored
@ -18,7 +18,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 1
|
||||||
|
|
||||||
- name: Install Python3
|
- name: Install Python3
|
||||||
run: sudo apt-get install python3 python3-setuptools python3-pip -y
|
run: sudo apt-get install python3 python3-setuptools python3-pip -y
|
||||||
|
|||||||
2
.github/workflows/ros_integration_tests.yml
vendored
2
.github/workflows/ros_integration_tests.yml
vendored
@ -30,7 +30,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 1
|
||||||
|
|
||||||
- name: Git Ownership Workaround
|
- name: Git Ownership Workaround
|
||||||
run: git config --system --add safe.directory '*'
|
run: git config --system --add safe.directory '*'
|
||||||
|
|||||||
2
.github/workflows/sitl_tests.yml
vendored
2
.github/workflows/sitl_tests.yml
vendored
@ -41,7 +41,7 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 1
|
||||||
|
|
||||||
- name: Git Ownership Workaround
|
- name: Git Ownership Workaround
|
||||||
run: git config --system --add safe.directory '*'
|
run: git config --system --add safe.directory '*'
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user