File tree Expand file tree Collapse file tree 3 files changed +42
-40
lines changed Expand file tree Collapse file tree 3 files changed +42
-40
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ name : Continuous Integration
2+
3+ on :
4+ push :
5+ paths-ignore :
6+ - " **/README.md"
7+ pull_request :
8+ workflow_dispatch :
9+
10+ env :
11+ CARGO_TERM_COLOR : always
12+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
13+
14+ jobs :
15+ rust-checks :
16+ name : Rust Checks
17+ runs-on : ubuntu-latest
18+ strategy :
19+ fail-fast : false
20+ matrix :
21+ action :
22+ - command : build
23+ args : --no-default-features --features=esp32c3 --target=riscv32imc-unknown-none-elf --release
24+ - command : fmt
25+ args : --all -- --check --color always
26+ - command : clippy
27+ args : --no-default-features --features=esp32c3 --target=riscv32imc-unknown-none-elf --workspace -- -D warnings
28+ steps :
29+ - name : Checkout repository
30+ uses : actions/checkout@v4
31+ - name : Setup Rust
32+ uses : dtolnay/rust-toolchain@v1
33+ with :
34+ target : riscv32imc-unknown-none-elf
35+ toolchain : stable
36+ components : rust-src, rustfmt, clippy
37+ - name : Enable caching
38+ uses : Swatinem/rust-cache@v2
39+ - name : Run command
40+ run : cargo ${{ matrix.action.command }} ${{ matrix.action.args }}
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ use std::{
33 path:: { Path , PathBuf } ,
44} ;
55
6- const VERSION_TEMPLATE : & ' static str = r#"
6+ const VERSION_TEMPLATE : & str = r#"
77pub const VERSION: &'static str = "{version}";
88pub const CHIP: &'static str = "{chip}";
99pub const FIRMWARE: &'static str = "{firmware}";
@@ -23,7 +23,7 @@ fn main() {
2323 crc_walkdir ( PathBuf :: from ( "src" ) , & mut hasher) ;
2424 let src_crc = hasher. finalize ( ) ;
2525
26- let mut version_str = if let Ok ( rel) = std:: env:: var ( "RELEASE_BUILD" ) {
26+ let version_str = if let Ok ( rel) = std:: env:: var ( "RELEASE_BUILD" ) {
2727 rel
2828 } else {
2929 let epoch = std:: time:: SystemTime :: now ( )
You can’t perform that action at this time.
0 commit comments