File tree Expand file tree Collapse file tree 3 files changed +16
-26
lines changed Expand file tree Collapse file tree 3 files changed +16
-26
lines changed Original file line number Diff line number Diff line change 4
4
name : Release
5
5
on :
6
6
push :
7
+ branches :
8
+ - ' master'
7
9
tags :
8
10
- ' v*'
9
- - ' test-action-release-*'
11
+ pull_request :
12
+ branches :
13
+ - ' master'
10
14
env :
11
15
GO111MODULE : on
12
16
jobs :
15
19
runs-on : macos-12
16
20
timeout-minutes : 20
17
21
steps :
22
+ - name : " Switch Xcode version to enable macOS 13 SDK"
23
+ # Xcode 14.1 added support for macOS 13 SDK.
24
+ # The default version is still 14.0.1, as of November 2022.
25
+ # https://github.com/actions/runner-images/blob/main/images/macos/macos-12-Readme.md#xcode
26
+ run : |
27
+ sudo xcode-select --switch /Applications/Xcode_14.1.app
28
+ xcrun --show-sdk-version
18
29
- uses : actions/setup-go@v3
19
30
with :
20
31
go-version : 1.19.x
81
92
The sha256sum of the SHA256SUMS file itself is \`${shasha}\` .
82
93
EOF
83
94
- name : " Create release"
95
+ if : github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
84
96
env :
85
97
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
86
98
run : |
Original file line number Diff line number Diff line change 83
83
- uses : actions/checkout@v3
84
84
with :
85
85
fetch-depth : 1
86
- - name : Test making darwin artifacts
87
- run : make artifacts-darwin
88
86
- name : Unit tests
89
87
run : go test -v ./...
90
88
- name : Make
@@ -243,23 +241,3 @@ jobs:
243
241
retry_on : error
244
242
max_attempts : 3
245
243
command : ./hack/test-upgrade.sh ${{ matrix.oldver }} ${{ github.sha }}
246
-
247
- artifacts-linux :
248
- name : Artifacts Linux
249
- runs-on : ubuntu-22.04
250
- timeout-minutes : 20
251
- steps :
252
- - uses : actions/setup-go@v3
253
- with :
254
- go-version : 1.19.x
255
- - name : Install gcc-aarch64-linux-gnu
256
- run : |
257
- sudo apt-get update
258
- sudo apt-get install -y gcc-aarch64-linux-gnu
259
- - uses : actions/checkout@v3
260
- with :
261
- fetch-depth : 1
262
- - name : Make linux artifacts
263
- run : make artifacts-linux
264
- - name : Make misc artifacts
265
- run : make artifacts-misc
Original file line number Diff line number Diff line change 15
15
16
16
GO_BUILDTAGS ?=
17
17
ifeq ($(GOOS ) ,darwin)
18
- MACOS_VERSION =$(shell sw_vers -productVersion | cut -d . -f 1)
19
- ifeq ($(shell test $(MACOS_VERSION ) -lt 13; echo $$? ) ,0)
20
- # The "vz" mode needs macOS 13 or later
18
+ MACOS_SDK_VERSION =$(shell xcrun --show-sdk-version | cut -d . -f 1)
19
+ ifeq ($(shell test $(MACOS_SDK_VERSION ) -lt 13; echo $$? ) ,0)
20
+ # The "vz" mode needs macOS 13 SDK or later
21
21
GO_BUILDTAGS += no_vz
22
22
endif
23
23
endif
You can’t perform that action at this time.
0 commit comments