@@ -10,30 +10,16 @@ variables:
1010
1111stages :
1212 - build
13- - release
1413
1514include :
1615 - remote : https://raw.githubusercontent.com/dehesselle/sdkchecksum/master/.gitlab-ci/verify_sdk-template.yml
1716
1817# ------------------------------------------------------------------------- build
1918
20- # Built the toolset, from sources to dmg.
21-
22- .build :
23- stage : build
24- script :
25- - !reference [ .verify_sdk, script ]
26- - ./build_toolset.sh
27- # Artifact size needs to stay below 1 GiB for GitLab.
28- - jhb/usr/bin/jhb run rustup self uninstall -y || true
29- - jhb/usr/bin/archive remove_nonessentials
30- - jhb/usr/bin/archive create_dmg
31- artifacts :
32- paths :
33- - mibap*.dmg
19+ # Build the dependencies.
3420
3521build :
36- extends : . build
22+ stage : build
3723 parallel :
3824 matrix :
3925 - RUNNER : [ "macosintel", "macosarm" ]
@@ -46,50 +32,13 @@ build:
4632 SDKROOT : /opt/sdks/MacOSX11.3.sdk
4733 tags :
4834 - ${RUNNER}
49- after_script :
50- # Cleanup is necessary for persistent runners but can be disabled for
51- # debugging purposes. (the number is not random, it's the project ID)
52- - |
53- source jhb/etc/jhb.conf.sh
54- if [ ! -f "$WRK_DIR"/no_cleanup-47632031 ]; then
55- rm -rf "${VER_DIR:?}"
56- fi
57-
58- # ----------------------------------------------------------------------- release
59-
60- # Release the toolset disk image.
61-
62- .release :
63- stage : release
64- rules :
65- - if : $CI_COMMIT_TAG =~ /^v\d+/
66- variables :
67- PACKAGE_REGISTRY_URL : " ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/mibap/${CI_COMMIT_TAG}"
68-
69- release:upload :
70- extends : .release
71- image : curlimages/curl:latest
72- needs :
73- - build
7435 script :
75- - |
76- for ARTIFACT in mibap*.dmg; do
77- curl --header "JOB-TOKEN: ${CI_JOB_TOKEN}" --upload-file ${ARTIFACT} ${PACKAGE_REGISTRY_URL}/${ARTIFACT}
78- done
79-
80- release:publish :
81- extends : .release
82- image : registry.gitlab.com/gitlab-org/release-cli:latest
83- needs :
84- - build
85- - release:upload
86- script :
87- - |
88- {
89- echo -n "release-cli create --name $CI_COMMIT_TAG --tag-name $CI_COMMIT_TAG "
90- for ARTIFACT in mibap*.dmg; do
91- echo -n "--assets-link '{\"name\":\"${ARTIFACT}\",\"url\":\"${PACKAGE_REGISTRY_URL}/${ARTIFACT}\"}' "
92- done
93- } > create_release.sh
94- chmod 755 create_release.sh
95- ./create_release.sh
36+ - !reference [ .verify_sdk, script ]
37+ - ./build_toolset.sh
38+ # Artifact size needs to stay below 1 GiB for GitLab.
39+ - jhb/usr/bin/jhb run rustup self uninstall -y || true
40+ - jhb/usr/bin/archive remove_nonessentials
41+ - jhb/usr/bin/archive create_dmg
42+ artifacts :
43+ paths :
44+ - jhb*.dmg
0 commit comments