File tree Expand file tree Collapse file tree 4 files changed +90
-11
lines changed Expand file tree Collapse file tree 4 files changed +90
-11
lines changed Original file line number Diff line number Diff line change
1
+ name : Build
2
+
3
+ on : [push, pull_request]
4
+
5
+ env :
6
+ CARGO_TERM_COLOR : always
7
+
8
+ jobs :
9
+ build :
10
+ runs-on : ubuntu-latest
11
+ steps :
12
+ - name : Checkout Code
13
+ uses : actions/checkout@v3
14
+ with :
15
+ submodules : true
16
+
17
+ - name : Install Rust
18
+ uses : actions-rs/toolchain@v1
19
+ with :
20
+ profile : minimal
21
+ toolchain : stable
22
+ override : true
23
+
24
+ - name : Build Code
25
+ run : cargo build --verbose
26
+
27
+ - name : Test Code
28
+ run : cargo test --verbose
29
+
30
+ - name : Get Branch Name
31
+ if : github.event_name == 'push' && startswith(github.ref, 'refs/tags/')
32
+ id : branch_name
33
+ run : |
34
+ echo ::set-output name=SOURCE_TAG::${GITHUB_REF#refs/tags/}
35
+
36
+ - name : Create Release
37
+ if : github.event_name == 'push' && startswith(github.ref, 'refs/tags/')
38
+ id : create_release
39
+ uses : actions/create-release@v1
40
+ env :
41
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
42
+ with :
43
+ tag_name : ${{ github.ref }}
44
+ release_name : Release ${{ steps.branch_name.outputs.SOURCE_TAG }}
45
+ draft : false
46
+ prerelease : false
Original file line number Diff line number Diff line change
1
+ name : Clippy
2
+
3
+ on : [push, pull_request]
4
+
5
+ env :
6
+ CARGO_TERM_COLOR : always
7
+
8
+ jobs :
9
+ clippy-check :
10
+ runs-on : ubuntu-latest
11
+ steps :
12
+ - name : Checkout Code
13
+ uses : actions/checkout@v3
14
+
15
+ - name : Install Rust
16
+ uses : actions-rs/toolchain@v1
17
+ with :
18
+ toolchain : stable
19
+ components : clippy
20
+
21
+ - name : Run Clippy
22
+ uses : actions-rs/clippy-check@v1
23
+ with :
24
+ token : ${{ secrets.GITHUB_TOKEN }}
25
+ args : --all-features
Original file line number Diff line number Diff line change
1
+ name : Format
2
+
3
+ on : [push, pull_request]
4
+
5
+ jobs :
6
+ format-check :
7
+ runs-on : ubuntu-latest
8
+ steps :
9
+ - name : Checkout Code
10
+ uses : actions/checkout@v3
11
+
12
+ - name : Install Rust
13
+ uses : actions-rs/toolchain@v1
14
+ with :
15
+ toolchain : stable
16
+ components : rustfmt
17
+
18
+ - name : Check Format
19
+ run : cargo fmt -- --check
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments