Skip to content

Commit 450ed18

Browse files
committed
Auto merge of rust-lang#129797 - workingjubilee:cleanup-apple-ci, r=<try>
Hunt down The Fruit Company's latest release I expect this to be... tedious. r? `@ghost` try-job: dist-aarch64-apple try-job: dist-x86_64-linux try-job: dist-x86_64-msvc
2 parents 0d63418 + 005f3fc commit 450ed18

File tree

2 files changed

+19
-6
lines changed

2 files changed

+19
-6
lines changed

src/ci/scripts/select-xcode.sh

+14-1
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,24 @@
11
#!/bin/bash
22
# This script selects the Xcode instance to use.
33

4-
set -euo pipefail
4+
set -euox pipefail
55
IFS=$'\n\t'
66

77
source "$(cd "$(dirname "$0")" && pwd)/../shared.sh"
88

99
if isMacOS; then
10+
old_xcode="$(xcode-select --print-path)"
11+
if [[ $old_xcode =~ $SELECT_XCODE ]]; then
12+
echo "xcode-select.sh's brutal hack may not be necessary?"
13+
exit 1
14+
elif [[ $SELECT_XCODE =~ "16" ]]; then
15+
echo "Using xcode 16? Please fix xcode-select.sh"
16+
exit 1
17+
else
18+
sudo xcode-select -s 16
19+
xcode_16_path="$(xcode-select --print-path)"
20+
sudo rm -rf "${xcode_16_path}/../../"
21+
fi
22+
sudo rm -rf "${old_xcode}/../../"
1023
sudo xcode-select -s "${SELECT_XCODE}"
1124
fi

src/ci/scripts/upload-artifacts.sh

+5-5
Original file line numberDiff line numberDiff line change
@@ -19,18 +19,18 @@ fi
1919
if [[ "${DEPLOY-0}" -eq "1" ]] || [[ "${DEPLOY_ALT-0}" -eq "1" ]]; then
2020
dist_dir="${build_dir}/dist"
2121
rm -rf "${dist_dir}/doc"
22-
cp -r "${dist_dir}"/* "${upload_dir}"
22+
mv -r "${dist_dir}"/* "${upload_dir}"
2323
fi
2424

2525
# CPU usage statistics.
26-
cp build/cpu-usage.csv "${upload_dir}/cpu-${CI_JOB_NAME}.csv"
26+
mv build/cpu-usage.csv "${upload_dir}/cpu-${CI_JOB_NAME}.csv"
2727

2828
# Build metrics generated by x.py.
29-
cp "${build_dir}/metrics.json" "${upload_dir}/metrics-${CI_JOB_NAME}.json"
29+
mv "${build_dir}/metrics.json" "${upload_dir}/metrics-${CI_JOB_NAME}.json"
3030

3131
# Toolstate data.
3232
if [[ -n "${DEPLOY_TOOLSTATES_JSON+x}" ]]; then
33-
cp /tmp/toolstate/toolstates.json "${upload_dir}/${DEPLOY_TOOLSTATES_JSON}"
33+
mv /tmp/toolstate/toolstates.json "${upload_dir}/${DEPLOY_TOOLSTATES_JSON}"
3434
fi
3535

3636
echo "Files that will be uploaded:"
@@ -55,7 +55,7 @@ then
5555
echo "# CI artifacts" >> "${GITHUB_STEP_SUMMARY}"
5656

5757
for filename in "${upload_dir}"/*.xz; do
58-
filename=`basename "${filename}"`
58+
filename=$(basename "${filename}")
5959
echo "- [${filename}](${access_url}/${filename})" >> "${GITHUB_STEP_SUMMARY}"
6060
done
6161
fi

0 commit comments

Comments
 (0)