File tree 3 files changed +36
-10
lines changed
3 files changed +36
-10
lines changed Original file line number Diff line number Diff line change 16
16
export SWIFTENV_ROOT="$HOME/.swiftenv"
17
17
export PATH="$SWIFTENV_ROOT/bin:$PATH"
18
18
eval "$(swiftenv init -)"
19
- swiftenv install $TOOLCHAIN_DOWNLOAD
19
+ ./ci/scripts/ install-toolchain.sh
20
20
make perf-tester
21
21
node ci/perf-tester
22
22
env :
23
- TOOLCHAIN_DOWNLOAD : https://github.com/swiftwasm/swift/releases/download/swift-wasm-5.3-SNAPSHOT-2020-08-10-a/swift-wasm-5.3-SNAPSHOT-2020-08-10-a-linux.tar.gz
24
23
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
Original file line number Diff line number Diff line change 6
6
strategy :
7
7
matrix :
8
8
os : [macOS-10.15, Ubuntu-18.04]
9
- include :
10
- - os : macOS-10.15
11
- toolchain : https://github.com/swiftwasm/swift/releases/download/swift-wasm-5.3-SNAPSHOT-2020-08-10-a/swift-wasm-5.3-SNAPSHOT-2020-08-10-a-osx.tar.gz
12
- - os : Ubuntu-18.04
13
- toolchain : https://github.com/swiftwasm/swift/releases/download/swift-wasm-5.3-SNAPSHOT-2020-08-10-a/swift-wasm-5.3-SNAPSHOT-2020-08-10-a-linux.tar.gz
14
9
runs-on : ${{ matrix.os }}
15
10
steps :
16
11
- name : Checkout
23
18
export SWIFTENV_ROOT="$HOME/.swiftenv"
24
19
export PATH="$SWIFTENV_ROOT/bin:$PATH"
25
20
eval "$(swiftenv init -)"
26
- swiftenv install $TOOLCHAIN_DOWNLOAD
21
+ ./ci/scripts/ install-toolchain.sh
27
22
make bootstrap
28
23
make test
29
- env :
30
- TOOLCHAIN_DOWNLOAD : ${{ matrix.toolchain }}
Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+ set -eu
3
+
4
+ scripts_dir=" $( cd " $( dirname $0 ) " && pwd) "
5
+ SWIFT_TAG=" swift-$( cat $scripts_dir /../../.swift-version) "
6
+
7
+ if [ -z " $( which swiftenv) " ]; then
8
+ echo " swiftenv not installed, please install it before this script"
9
+ exit 1
10
+ fi
11
+
12
+ case $( uname -s) in
13
+ Darwin)
14
+ TOOLCHAIN_DOWNLOAD=" $SWIFT_TAG -osx.tar.gz"
15
+ ;;
16
+ Linux)
17
+ if [ $( grep RELEASE /etc/lsb-release) == " DISTRIB_RELEASE=18.04" ]; then
18
+ TOOLCHAIN_DOWNLOAD=" $SWIFT_TAG -ubuntu18.04.tar.gz"
19
+ elif [ $( grep RELEASE /etc/lsb-release) == " DISTRIB_RELEASE=20.04" ]; then
20
+ TOOLCHAIN_DOWNLOAD=" $SWIFT_TAG -ubuntu20.04.tar.gz"
21
+ else
22
+ echo " Unknown Ubuntu version"
23
+ exit 1
24
+ fi
25
+ ;;
26
+ * )
27
+ echo " Unrecognised platform $( uname -s) "
28
+ exit 1
29
+ ;;
30
+ esac
31
+
32
+ TOOLCHAIN_DOWNLOAD_URL=" https://github.com/swiftwasm/swift/releases/download/$SWIFT_TAG /$TOOLCHAIN_DOWNLOAD "
33
+
34
+ swiftenv install " $TOOLCHAIN_DOWNLOAD_URL "
You can’t perform that action at this time.
0 commit comments