@@ -10,19 +10,10 @@ permissions:
10
10
11
11
jobs :
12
12
publish_crates :
13
- name : Release Libraries
13
+ name : Release
14
14
runs-on : ubuntu-latest
15
15
continue-on-error : true
16
16
if : github.ref_type == 'tag'
17
- strategy :
18
- matrix :
19
- include :
20
- - crate : rinex
21
- - crate : sp3
22
- - crate : sinex
23
- - crate : binex
24
- - crate : ublox-rnx
25
- - crate : rinex-cli
26
17
steps :
27
18
- name : Checkout
28
19
uses : actions/checkout@v4
@@ -35,105 +26,32 @@ jobs:
35
26
TOKEN : ${{ secrets.CRATES_IO_TOKEN }}
36
27
run : |
37
28
cargo login $TOKEN
38
- cargo publish -p ${{ matrix.crate }} - -allow-dirty
29
+ cargo publish --allow-dirty
39
30
40
31
build :
41
- name : build
42
- runs-on : ${{ matrix.os }}
43
- continue-on-error : true
44
- env :
45
- CARGO : cargo
46
- RUST_BACKTRACE : 1
47
- strategy :
48
- fail-fast : false
49
- matrix :
50
- include :
51
- - build : linux
52
- os : ubuntu-latest
53
- rust : stable
54
- target : x86_64-unknown-linux-gnu
55
- - build : macos
56
- os : macos-latest
57
- rust : stable
58
- target : x86_64-apple-darwin
59
- - build : macos
60
- os : macos-latest
61
- rust : stable
62
- target : aarch64-apple-darwin
63
- - build : win64-msvc
64
- os : windows-latest
65
- rust : stable
66
- target : x86_64-pc-windows-msvc
67
-
68
32
steps :
69
33
- name : Checkout repository
70
34
uses : actions/checkout@v4
71
35
72
- - name : Install Rust
73
- uses : actions-rs/toolchain@v1
74
- with :
75
- toolchain : ${{ matrix.rust }}
76
- target : ${{ matrix.target }}
77
-
78
- - name : UBX2RNX Dependencies
79
- if : matrix.build == 'linux'
80
- shell : bash
81
- run : |
82
- sudo apt-get update
83
- sudo apt-get install -y libudev-dev
84
-
85
- - name : Build applications
86
- shell : bash
87
- run : |
88
- CARGO_PROFILE_RELEASE_STRIP=symbols ${{ env.CARGO }} build \
89
- --verbose \
90
- --target ${{ matrix.target }} \
91
- --all-features \
92
- --release \
93
- -p rinex-cli \
94
- -p ublox-rnx
95
- ls -lah target/${{ matrix.target }}/release
96
- if [ "${{ matrix.os }}" = "windows-latest" ]; then
97
- rinexcli="target/${{ matrix.target }}/release/rinex-cli.exe"
98
- ubloxrnx="target/${{ matrix.target }}/release/ublox-rnx.exe"
99
- else
100
- rinexcli="target/${{ matrix.target }}/release/rinex-cli"
101
- ubloxrnx="target/${{ matrix.target }}/release/ublox-rnx"
102
- fi
103
- echo "RNXCLI=$rinexcli" >> $GITHUB_ENV
104
- echo "UBX2RNX=$ubloxrnx" >> $GITHUB_ENV
105
-
106
36
- name : Determine archive name
107
37
shell : bash
108
38
run : |
109
- echo "ARCHIVE=rinex-${{ github.ref_name }}-${{ matrix.target }} " >> $GITHUB_ENV
39
+ echo "ARCHIVE=rinex-${{ github.ref_name }}" >> $GITHUB_ENV
110
40
111
41
- name : Creating directory for archive
112
42
shell : bash
113
43
run : |
114
44
mkdir -p "$ARCHIVE"
115
- cp {README.md,LICENSE-MIT,LICENSE-APACHE} "$ARCHIVE"/
116
- cp "$RNXCLI" "$ARCHIVE"/
117
- cp "$UBX2RNX" "$ARCHIVE"/
45
+ cp {README.md,LICENSE} "$ARCHIVE"
118
46
119
47
- name : Gzip archive (Unix)
120
48
shell : bash
121
- if : matrix.os != 'windows-latest'
122
49
run : |
123
50
tar czf "$ARCHIVE.tar.gz" "$ARCHIVE"
124
51
shasum -a 256 "$ARCHIVE.tar.gz" > "$ARCHIVE.tar.gz.sha256"
125
52
echo "ASSET=$ARCHIVE.tar.gz" >> $GITHUB_ENV
126
53
echo "ASSET_SUM=$ARCHIVE.tar.gz.sha256" >> $GITHUB_ENV
127
54
128
- - name : Zip archive (Windows)
129
- shell : bash
130
- if : matrix.os == 'windows-latest'
131
- run : |
132
- 7z a "$ARCHIVE.zip" "$ARCHIVE"
133
- certutil -hashfile "$ARCHIVE.zip" SHA256 > "$ARCHIVE.zip.sha256"
134
- echo "ASSET=$ARCHIVE.zip" >> $GITHUB_ENV
135
- echo "ASSET_SUM=$ARCHIVE.zip.sha256" >> $GITHUB_ENV
136
-
137
55
- name : Upload artifacts
138
56
uses : actions/upload-artifact@v3
139
57
with :
@@ -165,122 +83,17 @@ jobs:
165
83
tag_name : ${{ github.ref_name }}
166
84
release_name : ${{ github.ref_name }}
167
85
168
- - name : Download x86_64-unknown-linux-gnu
169
- uses : actions/download-artifact@v3
170
- with :
171
- name : rinex-${{ github.ref_name }}-x86_64-unknown-linux-gnu.tar.gz
172
-
173
- - name : Download x86_64-unknown-linux-gnu (cksum)
174
- uses : actions/download-artifact@v3
175
- with :
176
- name : rinex-${{ github.ref_name }}-x86_64-unknown-linux-gnu.tar.gz.sha256
177
-
178
- - name : Upload x86_64-unknown-linux-gnu
179
- uses : actions/upload-release-asset@v1
180
- env :
181
- GITHUB_TOKEN : ${{ github.token }}
182
- with :
183
- upload_url : ${{ steps.create_release.outputs.upload_url }}
184
- asset_path : rinex-${{ github.ref_name }}-x86_64-unknown-linux-gnu.tar.gz
185
- asset_name : rinex-${{ github.ref_name }}-x86_64-unknown-linux-gnu.tar.gz
186
- asset_content_type : application/gzip
187
-
188
- - name : Upload x86_64-unknown-linux-gnu (cksum)
189
- uses : actions/upload-release-asset@v1
190
- env :
191
- GITHUB_TOKEN : ${{ github.token }}
192
- with :
193
- upload_url : ${{ steps.create_release.outputs.upload_url }}
194
- asset_path : rinex-${{ github.ref_name }}-x86_64-unknown-linux-gnu.tar.gz.sha256
195
- asset_name : rinex-${{ github.ref_name }}-x86_64-unknown-linux-gnu.tar.gz.sha256
196
- asset_content_type : application/gzip
197
-
198
- - name : Download x86_64-apple-darwin
199
- uses : actions/download-artifact@v3
200
- with :
201
- name : rinex-${{ github.ref_name }}-x86_64-apple-darwin.tar.gz
202
-
203
- - name : Download x86_64-apple-darwin (cksum)
204
- uses : actions/download-artifact@v3
205
- with :
206
- name : rinex-${{ github.ref_name }}-x86_64-apple-darwin.tar.gz.sha256
207
-
208
- - name : Upload x86_64-apple-darwin
209
- uses : actions/upload-release-asset@v1
210
- env :
211
- GITHUB_TOKEN : ${{ github.token }}
212
- with :
213
- upload_url : ${{ steps.create_release.outputs.upload_url }}
214
- asset_path : rinex-${{ github.ref_name }}-x86_64-apple-darwin.tar.gz
215
- asset_name : rinex-${{ github.ref_name }}-x86_64-apple-darwin.tar.gz
216
- asset_content_type : application/gzip
217
-
218
- - name : Upload x86_64-apple-darwin (cksum)
219
- uses : actions/upload-release-asset@v1
220
- env :
221
- GITHUB_TOKEN : ${{ github.token }}
222
- with :
223
- upload_url : ${{ steps.create_release.outputs.upload_url }}
224
- asset_path : rinex-${{ github.ref_name }}-x86_64-apple-darwin.tar.gz.sha256
225
- asset_name : rinex-${{ github.ref_name }}-x86_64-apple-darwin.tar.gz.sha256
226
- asset_content_type : application/gzip
227
-
228
- - name : Download aarch64-apple-darwin
86
+ - name : Download Artifact
229
87
uses : actions/download-artifact@v3
230
88
with :
231
- name : rinex-${{ github.ref_name }}-aarch64-apple-darwin.tar.gz
89
+ name : rinex-${{ github.ref_name }}
232
90
233
- - name : Download aarch64-apple-darwin (cksum)
234
- uses : actions/download-artifact@v3
235
- with :
236
- name : rinex-${{ github.ref_name }}-aarch64-apple-darwin.tar.gz.sha256
237
-
238
- - name : Upload aarch64-apple-darwin
239
- uses : actions/upload-release-asset@v1
240
- env :
241
- GITHUB_TOKEN : ${{ github.token }}
242
- with :
243
- upload_url : ${{ steps.create_release.outputs.upload_url }}
244
- asset_path : rinex-${{ github.ref_name }}-aarch64-apple-darwin.tar.gz
245
- asset_name : rinex-${{ github.ref_name }}-aarch64-apple-darwin.tar.gz
246
- asset_content_type : application/gzip
247
-
248
- - name : Upload aarch64-apple-darwin (cksum)
91
+ - name : Upload asset
249
92
uses : actions/upload-release-asset@v1
250
93
env :
251
94
GITHUB_TOKEN : ${{ github.token }}
252
95
with :
253
96
upload_url : ${{ steps.create_release.outputs.upload_url }}
254
- asset_path : rinex-${{ github.ref_name }}-aarch64-apple-darwin.tar.gz.sha256
255
- asset_name : rinex-${{ github.ref_name }}-aarch64-apple-darwin.tar.gz.sha256
97
+ asset_path : rinex-${{ github.ref_name }}
98
+ asset_name : rinex-${{ github.ref_name }}
256
99
asset_content_type : application/gzip
257
-
258
- - name : Download x86_64-pc-windows-msvc
259
- uses : actions/download-artifact@v3
260
- with :
261
- name : rinex-${{ github.ref_name }}-x86_64-pc-windows-msvc.zip
262
-
263
- - name : Download x86_64-pc-windows-msvc (cksum)
264
- uses : actions/download-artifact@v3
265
- with :
266
- name : rinex-${{ github.ref_name }}-x86_64-pc-windows-msvc.zip.sha256
267
-
268
- - name : Upload x86_64-pc-windows-msvc
269
- uses : actions/upload-release-asset@v1
270
- env :
271
- GITHUB_TOKEN : ${{ github.token }}
272
- with :
273
- upload_url : ${{ steps.create_release.outputs.upload_url }}
274
- asset_path : rinex-${{ github.ref_name }}-x86_64-pc-windows-msvc.zip
275
- asset_name : rinex-${{ github.ref_name }}-x86_64-pc-windows-msvc.zip
276
- asset_content_type : application/zip
277
-
278
- - name : Upload x86_64-pc-windows-msvc (cksum)
279
- uses : actions/upload-release-asset@v1
280
- env :
281
- GITHUB_TOKEN : ${{ github.token }}
282
- with :
283
- upload_url : ${{ steps.create_release.outputs.upload_url }}
284
- asset_path : rinex-${{ github.ref_name }}-x86_64-pc-windows-msvc.zip.sha256
285
- asset_name : rinex-${{ github.ref_name }}-x86_64-pc-windows-msvc.zip.sha256
286
- asset_content_type : application/zip
0 commit comments