@@ -21,11 +21,21 @@ jobs:
21
21
armv7-unknown-linux-gnueabihf,
22
22
]
23
23
steps :
24
- - uses : actions/checkout@v2
25
- - uses : actions/setup-node@v2
24
+ - name : Checkout
25
+ uses : actions/checkout@v2
26
+ - name : Install Rust
27
+ uses : actions-rs/toolchain@v1
28
+ with :
29
+ profile : minimal
30
+ toolchain : stable
31
+ - name : Cache
32
+ uses : Swatinem/rust-cache@v1
33
+ - name : Node
34
+ uses : actions/setup-node@v2
26
35
with :
27
36
node-version : " 16"
28
- - uses : google-github-actions/setup-gcloud@master
37
+ - name : GCloud
38
+ uses : google-github-actions/setup-gcloud@master
29
39
with :
30
40
project_id : ${{ secrets.GCP_PROJECT_ID }}
31
41
service_account_key : ${{ secrets.GCP_SA_KEY }}
46
56
rustup target add ${{ matrix.target }}
47
57
48
58
# build and deploy CLI
49
- cargo build -p tmc-langs-cli --release --verbose -- target ${{ matrix.target }}
59
+ cargo build -p tmc-langs-cli --release --target ${{ matrix.target }}
50
60
gsutil cp target/${{ matrix.target }}/release/tmc-langs-cli gs://${{ secrets.GCP_BUCKET }}/tmc-langs-rust/tmc-langs-cli-${{ matrix.target }}-$TAG
51
61
52
62
# build and deploy Node module
@@ -60,19 +70,30 @@ jobs:
60
70
matrix :
61
71
target : [i686-pc-windows-msvc, x86_64-pc-windows-msvc]
62
72
steps :
63
- - uses : actions/checkout@v2
64
- - uses : actions/setup-node@v2
73
+ - name : Checkout
74
+ uses : actions/checkout@v2
75
+ - name : Install Rust
76
+ uses : actions-rs/toolchain@v1
77
+ with :
78
+ profile : minimal
79
+ toolchain : stable
80
+ - name : Cache
81
+ uses : Swatinem/rust-cache@v1
82
+ - name : Node
83
+ uses : actions/setup-node@v2
65
84
with :
66
85
node-version : " 16"
67
- - uses : google-github-actions/setup-gcloud@master
86
+ - name : GCloud
87
+ uses : google-github-actions/setup-gcloud@master
68
88
with :
69
89
project_id : ${{ secrets.GCP_PROJECT_ID }}
70
90
service_account_key : ${{ secrets.GCP_SA_KEY }}
91
+
71
92
- name : Build
72
93
run : |
73
94
rustup target add ${{ matrix.target }}
74
95
$env:RUSTFLAGS="-C target-feature=+crt-static" # crt-static is set with RUSTFLAGS to statically link MSVCRT (VCRUNTIME140.dll)
75
- cargo build -p tmc-langs-cli --release --verbose -- target ${{ matrix.target }}
96
+ cargo build -p tmc-langs-cli --release --target ${{ matrix.target }}
76
97
cd ./bindings/tmc-langs-node && npm install && npm run build -- --release --target ${{ matrix.target }}
77
98
- name : Deploy
78
99
run : |
@@ -84,17 +105,28 @@ jobs:
84
105
macos :
85
106
runs-on : macos-latest
86
107
steps :
87
- - uses : actions/checkout@v2
88
- - uses : actions/setup-node@v2
108
+ - name : Checkout
109
+ uses : actions/checkout@v2
110
+ - name : Install Rust
111
+ uses : actions-rs/toolchain@v1
112
+ with :
113
+ profile : minimal
114
+ toolchain : stable
115
+ - name : Cache
116
+ uses : Swatinem/rust-cache@v1
117
+ - name : Node
118
+ uses : actions/setup-node@v2
89
119
with :
90
120
node-version : " 16"
91
- - uses : google-github-actions/setup-gcloud@master
121
+ - name : GCloud
122
+ uses : google-github-actions/setup-gcloud@master
92
123
with :
93
124
project_id : ${{ secrets.GCP_PROJECT_ID }}
94
125
service_account_key : ${{ secrets.GCP_SA_KEY }}
126
+
95
127
- name : Cargo build
96
128
run : |
97
- cargo build -p tmc-langs-cli --release --verbose
129
+ cargo build -p tmc-langs-cli --release
98
130
npm --prefix ./bindings/tmc-langs-node install
99
131
npm run --prefix ./bindings/tmc-langs-node build -- --release
100
132
- name : Sign
0 commit comments