Skip to content

Commit 205e5f9

Browse files
committed
Fix CI
1 parent 93bf9f0 commit 205e5f9

File tree

2 files changed

+21
-19
lines changed

2 files changed

+21
-19
lines changed

.github/workflows/CI.yaml

Lines changed: 21 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,6 @@ jobs:
99
- name: Checkout
1010
uses: actions/checkout@v2
1111

12-
- name: Set non-interactive
13-
run: |
14-
export DEBIAN_FRONTEND=noninteractive
15-
export DEBCONF_NONINTERACTIVE_SEEN=true
16-
1712
- name: Test swiftbox version
1813
run: |
1914
chmod +x swiftbox.sh
@@ -97,23 +92,29 @@ jobs:
9792
- name: Checkout
9893
uses: actions/checkout@v2
9994

100-
- name: Set non-interactive
101-
run: |
102-
echo "::set-env name=DEBIAN_FRONTEND:noninteractive"
103-
echo "::set-env name=DEBCONF_NONINTERACTIVE_SEEN:true"
104-
10595
- name: Test swiftbox version
10696
run: |
10797
chmod +x swiftbox.sh
10898
./swiftbox.sh version
10999
110100
- name: Test swiftbox get nightly
101+
env:
102+
DEBIAN_FRONTEND: noninteractive
103+
DEBCONF_NONINTERACTIVE_SEEN: true
111104
run: ./swiftbox.sh get nightly
112105

113106
- name: Test Swift status
107+
shell: bash
114108
run: |
115109
source /etc/environment
116-
source $HOME/.swiftbox/env.sh
110+
if [ -f $HOME/.swiftbox/env.sh ]
111+
then
112+
source $HOME/.swiftbox/env.sh
113+
fi
114+
if [ -f /opt/swiftbox/env.sh ]
115+
then
116+
source /opt/swiftbox/env.sh
117+
fi
117118
echo "\$PATH=$PATH"
118119
./swiftbox.sh list
119120
which swift
@@ -170,7 +171,14 @@ jobs:
170171
171172
- name: Test Swift compiler
172173
run: |
173-
source /etc/environment
174-
source $HOME/.swiftbox/env.sh
174+
source /etc/environment
175+
if [ -f $HOME/.swiftbox/env.sh ]
176+
then
177+
source $HOME/.swiftbox/env.sh
178+
fi
179+
if [ -f /opt/swiftbox/env.sh ]
180+
then
181+
source /opt/swiftbox/env.sh
182+
fi
175183
swift test.swift
176184
swiftc test.swift -o test && ./test

.github/workflows/Tag.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,6 @@ jobs:
5151
image: ubuntu:20.04
5252
runs-on: ubuntu-latest
5353
steps:
54-
55-
- name: Set non-interactive
56-
run: |
57-
export DEBIAN_FRONTEND=noninteractive
58-
export DEBCONF_NONINTERACTIVE_SEEN=true
59-
6054
- name: Install curl
6155
run: |
6256
apt-get update

0 commit comments

Comments
 (0)