Skip to content

Commit 60ca6b5

Browse files
Use swiftwasm/setup-swiftwasm instead of swiftenv on CI (swiftwasm#215)
* Use swiftwasm/setup-swiftwasm instead of swiftenv on CI * Update .github/workflows/perf.yml also * Update .github/workflows/compatibility.yml also
1 parent dac9d7b commit 60ca6b5

File tree

4 files changed

+7
-20
lines changed

4 files changed

+7
-20
lines changed

.github/workflows/compatibility.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,16 @@ on:
66
jobs:
77
test:
88
name: Check source code compatibility
9-
runs-on: Ubuntu-18.04
9+
runs-on: ubuntu-20.04
1010
steps:
1111
- name: Checkout
1212
uses: actions/checkout@v2
1313
with:
1414
fetch-depth: 1
15+
- uses: swiftwasm/setup-swiftwasm@v1
1516
- name: Run Test
1617
run: |
1718
set -eux
18-
git clone https://github.com/kylef/swiftenv.git ~/.swiftenv
19-
export SWIFTENV_ROOT="$HOME/.swiftenv"
20-
export PATH="$SWIFTENV_ROOT/bin:$PATH"
21-
eval "$(swiftenv init -)"
2219
make bootstrap
2320
cd Example/JavaScriptKitExample
2421
swift build --triple wasm32-unknown-wasi

.github/workflows/perf.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,15 @@ on: [pull_request]
44

55
jobs:
66
perf:
7-
runs-on: Ubuntu-18.04
7+
runs-on: ubuntu-20.04
88
steps:
99
- name: Checkout
1010
uses: actions/checkout@master
1111
with:
1212
fetch-depth: 1
13+
- uses: swiftwasm/setup-swiftwasm@v1
1314
- name: Run Benchmark
1415
run: |
15-
git clone https://github.com/kylef/swiftenv.git ~/.swiftenv
16-
export SWIFTENV_ROOT="$HOME/.swiftenv"
17-
export PATH="$SWIFTENV_ROOT/bin:$PATH"
18-
eval "$(swiftenv init -)"
1916
make bootstrap
2017
make perf-tester
2118
node ci/perf-tester

.github/workflows/test.yml

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,9 @@ jobs:
3333
uses: actions/checkout@master
3434
with:
3535
fetch-depth: 1
36-
- name: Install swiftenv
37-
run: |
38-
git clone https://github.com/kylef/swiftenv.git ~/.swiftenv
39-
export SWIFTENV_ROOT="$HOME/.swiftenv"
40-
export PATH="$SWIFTENV_ROOT/bin:$PATH"
41-
eval "$(swiftenv init -)"
42-
echo $PATH >> $GITHUB_PATH
43-
env >> $GITHUB_ENV
44-
echo ${{ matrix.entry.toolchain }} > .swift-version
36+
- uses: swiftwasm/setup-swiftwasm@v1
37+
with:
38+
swift-version: ${{ matrix.entry.toolchain }}
4539
- run: make bootstrap
4640
- run: make test
4741
- run: make unittest

Makefile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ MAKEFILE_DIR := $(dir $(lastword $(MAKEFILE_LIST)))
22

33
.PHONY: bootstrap
44
bootstrap:
5-
./scripts/install-toolchain.sh
65
npm ci
76

87
.PHONY: build

0 commit comments

Comments
 (0)