ci: compatible with macos base64 version

This commit is contained in:
Fu Hanxi
2026-02-10 10:54:18 +01:00
parent c37ec038ad
commit bf9d32d514
3 changed files with 9 additions and 2 deletions
-1
View File
@@ -258,7 +258,6 @@ variables:
tags:
- macos-tart
image: macos-sequoia-idf-v6.1
cache: [] # cache are built for amd64 linux runners, useless here
after_script: [] # ccache now is disabled for macos brew runners
timeout: 30m
@@ -12,6 +12,7 @@ all_build_finished:
expire_in: 1 week
when: always
before_script: []
dependencies: []
script:
- echo "all test jobs finished"
+8 -1
View File
@@ -5,7 +5,14 @@ function add_ssh_keys() {
mkdir -p ~/.ssh
chmod 700 ~/.ssh
echo -n "${key_string}" >~/.ssh/id_rsa_base64
base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 >~/.ssh/id_rsa
# Detect base64 implementation via --help output
if base64 --help 2>&1 | grep -q -- '--ignore-garbage'; then
# GNU coreutils base64
base64 --decode --ignore-garbage ~/.ssh/id_rsa_base64 >~/.ssh/id_rsa
else
# macOS/BSD base64 - requires stdin or -i flag
base64 --decode -i ~/.ssh/id_rsa_base64 -o ~/.ssh/id_rsa
fi
chmod 600 ~/.ssh/id_rsa
}