File tree Expand file tree Collapse file tree 1 file changed +17
-2
lines changed
.github/actions/install-swift Expand file tree Collapse file tree 1 file changed +17
-2
lines changed Original file line number Diff line number Diff line change 30
30
key : swift-${{ runner.os }}-${{ hashFiles('**/.swift-version', '.github/actions/install-swift/action.yml') }}
31
31
32
32
- name : Install `apt` Dependencies
33
- if : steps.cache-swift.outputs.cache-hit != 'true'
33
+ if : runner.os == 'Linux' && steps.cache-swift.outputs.cache-hit != 'true'
34
34
shell : bash
35
35
run : |
36
36
SUDO=$(if [[ $EUID -ne 0 ]]; then echo sudo; fi)
40
40
DEBIAN_FRONTEND : noninteractive
41
41
42
42
- name : Install Swiftly
43
- if : steps.cache-swift.outputs.cache-hit != 'true'
43
+ if : runner.os == 'Linux' && steps.cache-swift.outputs.cache-hit != 'true'
44
44
shell : bash
45
45
run : |
46
46
SWIFTLY_VERSION=1.0.1
54
54
--quiet-shell-followup \
55
55
--no-modify-profile
56
56
57
+ - name : Install Swiftly
58
+ if : runner.os == 'macOS' && steps.cache-swift.outputs.cache-hit != 'true'
59
+ shell : bash
60
+ run : |
61
+ SWIFTLY_VERSION=1.0.1
62
+ UNAME=$(uname -m)
63
+ SWIFTLY_PKG=swiftly-$SWIFTLY_VERSION.pkg
64
+ curl -O "https://download.swift.org/swiftly/darwin/$SWIFTLY_PKG"
65
+ installer -pkg $SWIFTLY_PKG -target CurrentUserHomeDirectory
66
+ ./swiftly init \
67
+ --skip-install \
68
+ --assume-yes \
69
+ --quiet-shell-followup \
70
+ --no-modify-profile
71
+
57
72
- name : Install Swift
58
73
if : steps.cache-swift.outputs.cache-hit != 'true'
59
74
shell : bash
You can’t perform that action at this time.
0 commit comments