ci: bsim update step: Do not affect global git config

When updating the bsim install in the docker image's
/opt/bsim_west to the version pointed in the Zephyr
manifest, we are detaching the head to that version.
We suppress the "You are in 'detached HEAD' state..."
git warning as it is just noise in CI.

So far we were doing it by globally supressing that
warning. Let's instead just supress it for the
command in question so we don't change global
git config against expectations.

Signed-off-by: Alberto Escolar Piedras <alberto.escolar.piedras@nordicsemi.no>
This commit is contained in:
Alberto Escolar Piedras 2024-03-14 08:38:29 +01:00 committed by Alberto Escolar
parent 5158ea4af0
commit cbef916973
4 changed files with 4 additions and 8 deletions

View file

@ -145,8 +145,7 @@ jobs:
echo "Manifest points to bsim sha $BSIM_VERSION" echo "Manifest points to bsim sha $BSIM_VERSION"
cd /opt/bsim_west/bsim cd /opt/bsim_west/bsim
git fetch -n origin ${BSIM_VERSION} git fetch -n origin ${BSIM_VERSION}
git config --global advice.detachedHead false git -c advice.detachedHead=false checkout ${BSIM_VERSION}
git checkout ${BSIM_VERSION}
west update west update
make everything -s -j 8 make everything -s -j 8

View file

@ -95,8 +95,7 @@ jobs:
echo "Manifest points to bsim sha $BSIM_VERSION" echo "Manifest points to bsim sha $BSIM_VERSION"
cd /opt/bsim_west/bsim cd /opt/bsim_west/bsim
git fetch -n origin ${BSIM_VERSION} git fetch -n origin ${BSIM_VERSION}
git config --global advice.detachedHead false git -c advice.detachedHead=false checkout ${BSIM_VERSION}
git checkout ${BSIM_VERSION}
west update west update
make everything -s -j 8 make everything -s -j 8

View file

@ -91,8 +91,7 @@ jobs:
echo "Manifest points to bsim sha $BSIM_VERSION" echo "Manifest points to bsim sha $BSIM_VERSION"
cd /opt/bsim_west/bsim cd /opt/bsim_west/bsim
git fetch -n origin ${BSIM_VERSION} git fetch -n origin ${BSIM_VERSION}
git config --global advice.detachedHead false git -c advice.detachedHead=false checkout ${BSIM_VERSION}
git checkout ${BSIM_VERSION}
west update west update
make everything -s -j 8 make everything -s -j 8

View file

@ -219,8 +219,7 @@ jobs:
echo "Manifest points to bsim sha $BSIM_VERSION" echo "Manifest points to bsim sha $BSIM_VERSION"
cd /opt/bsim_west/bsim cd /opt/bsim_west/bsim
git fetch -n origin ${BSIM_VERSION} git fetch -n origin ${BSIM_VERSION}
git config --global advice.detachedHead false git -c advice.detachedHead=false checkout ${BSIM_VERSION}
git checkout ${BSIM_VERSION}
west update west update
make everything -s -j 8 make everything -s -j 8