File tree Expand file tree Collapse file tree 2 files changed +48
-5
lines changed Expand file tree Collapse file tree 2 files changed +48
-5
lines changed Original file line number Diff line number Diff line change
1
+ name : installer
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - main
7
+ paths :
8
+ - " installer.sh"
9
+ pull_request :
10
+ branches :
11
+ - main
12
+
13
+ jobs :
14
+ ubuntu :
15
+ name : Test installer on ubuntu
16
+ runs-on : ubuntu-latest
17
+ steps :
18
+ - name : Checkout repo
19
+ uses : actions/checkout@v2
20
+
21
+ - name : Install code-server
22
+ run : ./install.sh
23
+
24
+ - name : Test code-server
25
+ run : yarn test:standalone-release code-server
26
+
27
+ macos :
28
+ name : Test installer on macOS
29
+ runs-on : macos-latest
30
+
31
+ steps :
32
+ - name : Checkout repo
33
+ uses : actions/checkout@v2
34
+
35
+ - name : Install code-server
36
+ run : ./install.sh
37
+
38
+ - name : Test code-server
39
+ run : yarn test:standalone-release code-server
Original file line number Diff line number Diff line change 1
1
#! /usr/bin/env bash
2
2
set -euo pipefail
3
3
4
- # Makes sure the release works.
4
+ # Make sure a code-server release works. You can pass in the path otherwise it
5
+ # will use release-standalone in the current directory.
6
+ #
5
7
# This is to make sure we don't have Node version errors or any other
6
8
# compilation-related errors.
7
9
main () {
@@ -10,12 +12,14 @@ main() {
10
12
local EXTENSIONS_DIR
11
13
EXTENSIONS_DIR=" $( mktemp -d) "
12
14
13
- echo " Testing standalone release. "
15
+ local path= ${1 :- . / release-standalone / bin / code-server}
14
16
15
- # Note: using a basic theme extension because it doesn't update often and is more reliable for testing
16
- ./release-standalone/bin/code-server --extensions-dir " $EXTENSIONS_DIR " --install-extension wesbos.theme-cobalt2
17
+ echo " Testing standalone release in $path ."
18
+
19
+ # NOTE: using a basic theme extension because it doesn't update often and is more reliable for testing
20
+ " $path " --extensions-dir " $EXTENSIONS_DIR " --install-extension wesbos.theme-cobalt2
17
21
local installed_extensions
18
- installed_extensions=" $( ./release-standalone/bin/code-server --extensions-dir " $EXTENSIONS_DIR " --list-extensions 2>&1 ) "
22
+ installed_extensions=" $( " $path " --extensions-dir " $EXTENSIONS_DIR " --list-extensions 2>&1 ) "
19
23
# We use grep as wesbos.theme-cobalt2 may have dependency extensions that change.
20
24
if ! echo " $installed_extensions " | grep -q " wesbos.theme-cobalt2" ; then
21
25
echo " Unexpected output from listing extensions:"
You can’t perform that action at this time.
0 commit comments