.github: fix git directory permissions

This commit is contained in:
Pierre Kancir 2023-02-03 18:45:49 +01:00 committed by Peter Barker
parent 5df7e4e32b
commit a694b68519
14 changed files with 24 additions and 0 deletions

View File

@ -85,6 +85,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "chibios-clang" ]]; then if [[ ${{ matrix.toolchain }} == "chibios-clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++

View File

@ -70,6 +70,7 @@ jobs:
TERM: xterm TERM: xterm
shell: 'script -q -e -c "bash {0}"' shell: 'script -q -e -c "bash {0}"'
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
python -m pip install --progress-bar off --user mavproxy python -m pip install --progress-bar off --user mavproxy
python -m pip uninstall -y pymavlink python -m pip uninstall -y pymavlink

View File

@ -102,6 +102,7 @@ jobs:
TZ: Europe/Paris TZ: Europe/Paris
shell: 'script -q -e -c "bash {0}"' shell: 'script -q -e -c "bash {0}"'
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
source ~/.bashrc source ~/.bashrc
git config --global --add safe.directory /__w/ardupilot/ardupilot git config --global --add safe.directory /__w/ardupilot/ardupilot
./waf configure ./waf configure
@ -114,6 +115,7 @@ jobs:
TZ: Europe/Paris TZ: Europe/Paris
shell: 'script -q -e -c "bash {0}"' shell: 'script -q -e -c "bash {0}"'
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
source ~/.bashrc source ~/.bashrc
case ${{matrix.os}} in case ${{matrix.os}} in
*"archlinux"*) *"archlinux"*)

View File

@ -66,6 +66,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++

View File

@ -65,6 +65,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++

View File

@ -35,6 +35,7 @@ jobs:
- name: build sitl # we don't really need to build the full code, just trigger docs re-gen with --scripting-docs, timeout after 10 seconds - name: build sitl # we don't really need to build the full code, just trigger docs re-gen with --scripting-docs, timeout after 10 seconds
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
./waf configure --board sitl ./waf configure --board sitl
timeout 10 ./waf antennatracker --scripting-docs || code=$?; if [[ $code -ne 124 && $code -ne 0 ]]; then exit $code; fi timeout 10 ./waf antennatracker --scripting-docs || code=$?; if [[ $code -ne 124 && $code -ne 0 ]]; then exit $code; fi

View File

@ -57,6 +57,7 @@ jobs:
- name: build copter ${{ matrix.toolchain }} - name: build copter ${{ matrix.toolchain }}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++
@ -111,6 +112,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
Tools/scripts/build_ci.sh Tools/scripts/build_ci.sh
@ -163,6 +165,7 @@ jobs:
- name: build heli - name: build heli
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
./waf configure --board sitl ./waf configure --board sitl
./waf build --target bin/arducopter-heli ./waf build --target bin/arducopter-heli
@ -205,6 +208,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
Tools/scripts/build_ci.sh Tools/scripts/build_ci.sh

View File

@ -63,6 +63,7 @@ jobs:
- name: build sitl_periph_gps - name: build sitl_periph_gps
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
./waf configure --board sitl_periph_gps ./waf configure --board sitl_periph_gps
./waf build --target bin/AP_Periph ./waf build --target bin/AP_Periph
@ -121,6 +122,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
kernel_ver=`uname -r` kernel_ver=`uname -r`
if [ "$kernel_ver" = "5.4.0-1032-azure" ] || [ "$kernel_ver" = "5.11.4-051104-generic" ]; then echo "Unsupported Kernel $kernel_ver" && exit 0; fi; if [ "$kernel_ver" = "5.4.0-1032-azure" ] || [ "$kernel_ver" = "5.11.4-051104-generic" ]; then echo "Unsupported Kernel $kernel_ver" && exit 0; fi;
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"

View File

@ -57,6 +57,7 @@ jobs:
- name: build plane ${{ matrix.toolchain }} - name: build plane ${{ matrix.toolchain }}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++
@ -106,6 +107,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
Tools/scripts/build_ci.sh Tools/scripts/build_ci.sh

View File

@ -57,6 +57,7 @@ jobs:
- name: build rover ${{ matrix.toolchain }} - name: build rover ${{ matrix.toolchain }}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++
@ -107,6 +108,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
Tools/scripts/build_ci.sh Tools/scripts/build_ci.sh

View File

@ -57,6 +57,7 @@ jobs:
- name: build sub ${{ matrix.toolchain }} - name: build sub ${{ matrix.toolchain }}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++
@ -105,6 +106,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
Tools/scripts/build_ci.sh Tools/scripts/build_ci.sh

View File

@ -57,6 +57,7 @@ jobs:
- name: build tracker ${{ matrix.toolchain }} - name: build tracker ${{ matrix.toolchain }}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++
@ -105,6 +106,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
Tools/scripts/build_ci.sh Tools/scripts/build_ci.sh

View File

@ -57,6 +57,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
cd base_branch cd base_branch
./waf configure --board ${{matrix.config}} ./waf configure --board ${{matrix.config}}
@ -102,6 +103,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: bash shell: bash
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
PATH="/github/home/.local/bin:$PATH" PATH="/github/home/.local/bin:$PATH"
cd pr/ cd pr/
git config user.email "ardupilot-ci@ardupilot.org" git config user.email "ardupilot-ci@ardupilot.org"

View File

@ -52,6 +52,7 @@ jobs:
CI_BUILD_TARGET: ${{matrix.config}} CI_BUILD_TARGET: ${{matrix.config}}
shell: 'script -q -e -c "bash {0}"' shell: 'script -q -e -c "bash {0}"'
run: | run: |
git config --global --add safe.directory ${GITHUB_WORKSPACE}
if [[ ${{ matrix.toolchain }} == "clang" ]]; then if [[ ${{ matrix.toolchain }} == "clang" ]]; then
export CC=clang export CC=clang
export CXX=clang++ export CXX=clang++