1
1
name : CI-Release
2
2
on :
3
- pull_request :
4
3
push :
5
4
branches :
6
- - master
5
+ - release
7
6
8
7
jobs :
9
8
rust :
15
14
env :
16
15
RUSTFLAGS : -D warnings
17
16
CARGO_INCREMENTAL : 0
18
- RUN_SLOW_TESTS : 1
19
17
RUSTUP_MAX_RETRIES : 10
20
18
CARGO_NET_RETRY : 10
21
19
steps :
@@ -39,47 +37,26 @@ jobs:
39
37
override : true
40
38
components : rustfmt, rust-src
41
39
42
- - name : Cache cargo registry
43
- uses : actions/cache@v1
44
- with :
45
- path : ~/.cargo/registry
46
- key : ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
47
-
48
- - name : Cache cargo index
49
- uses : actions/cache@v1
50
- with :
51
- path : ~/.cargo/git
52
- key : ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }}
53
-
54
- - name : Cache cargo target dir
55
- uses : actions/cache@v1
56
- with :
57
- path : target
58
- key : ${{ runner.os }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }}
59
-
60
- - name : Compile and Test
40
+ - name : Build
61
41
uses : actions-rs/cargo@v1
62
42
with :
63
- command : test
64
- args : --release --all-targets
43
+ command : build
44
+ args : --release --package ra_lsp_server --bin ra_lsp_server
65
45
66
- - name : Prepare cache
67
- run : cargo xtask pre-cache
46
+ - name : Strip symbols
47
+ if : matrix.os == 'ubuntu-latest'
48
+ run : strip ./target/release/ra_lsp_server
68
49
69
- - name : Prepare cache 2
70
- if : matrix.os == 'windows-latest'
71
- run : Remove-Item ./target/release/xtask.exe
72
-
73
- - name : Creat distribution dir
50
+ - name : Create distribution dir
74
51
run : mkdir ./dist
75
52
76
- - name : Copy binaries (non-win )
53
+ - name : Copy binaries (unix )
77
54
if : matrix.os != 'windows-latest'
78
55
run : cp ./target/release/ra_lsp_server ./dist
79
56
80
57
- name : Copy binaries (win)
81
58
if : matrix.os == 'windows-latest'
82
- run : copy ./target/release/ra_lsp_server.* ./dist
59
+ run : copy ./target/release/ra_lsp_server.exe ./dist
83
60
84
61
- name : Upload artifacts
85
62
uses : actions/upload-artifact@v1
90
67
type-script :
91
68
name : TypeScript
92
69
runs-on : ubuntu-latest
93
- env :
94
- CXX : g++-4.9
95
- CC : gcc-4.9
96
70
steps :
97
71
- name : Checkout repository
98
72
uses : actions/checkout@v1
@@ -104,20 +78,18 @@ jobs:
104
78
105
79
- run : npm ci
106
80
working-directory : ./editors/code
81
+
107
82
- run : npm run package --scripts-prepend-node-path
108
83
working-directory : ./editors/code
109
84
110
- - name : Create distribution directory
111
- run : mkdir ./dist
112
-
113
85
- name : Copy vscode extension
114
- run : mkdir ./dist/code && cp ./editors/code/*.vsix ./dist/code/
86
+ run : mkdir -p ./dist/code && cp ./editors/code/*.vsix ./dist/code/
115
87
116
88
- name : Copy emacs mode
117
89
run : cp -R ./editors/emacs ./dist/
118
90
119
91
- name : Upload artifacts
120
92
uses : actions/upload-artifact@v1
121
93
with :
122
- name : editors
94
+ name : editor-plugins
123
95
path : ./dist
0 commit comments