-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
da450a0
commit e494537
Showing
3 changed files
with
66 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: Build and test rust code | ||
|
||
on: | ||
push: | ||
pull_request: | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
build_and_test: | ||
runs-on: ubuntu-latest | ||
name: Build and test binary | ||
steps: | ||
- name: Cache cargo registry | ||
uses: actions/cache@v3 | ||
with: | ||
path: ~/.cargo/registry | ||
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }} | ||
- name: Cache cargo index | ||
uses: actions/cache@v3 | ||
with: | ||
path: ~/.cargo/git | ||
key: ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }} | ||
- name: Cache cargo build | ||
uses: actions/cache@v3 | ||
with: | ||
path: target | ||
key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('**/Cargo.lock') }} | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Set up toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: 1.76 | ||
override: true | ||
- name: Build | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: build | ||
args: --release | ||
- name: Test | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: test | ||
args: --release |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,7 +18,7 @@ include = [ | |
] | ||
|
||
[badges] | ||
github = { repository = "ipmitool-dcmi-power-reading", branch = "master" } | ||
github = { repository = "ipmitool-dcmi-power-reading", branch = "main" } | ||
is-it-maintained-issue-resolution = { repository = "ipmitool-dcmi-power-reading" } | ||
is-it-maintained-open-issues = { repository = "ipmitool-dcmi-power-reading" } | ||
maintenance = { status = "passively-maintained" } | ||
|
@@ -35,6 +35,20 @@ lto = true | |
|
||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | ||
|
||
[package.metadata.deb] | ||
maintainer = "William Desportes <[email protected]>" | ||
copyright = "2024, William Desportes <[email protected]>" | ||
license-file = ["LICENSE"] | ||
extended-description = """\ | ||
The Rust implementation of \"ipmitool dcmi power reading\"""" | ||
depends = "$auto" | ||
section = "utility" | ||
priority = "optional" | ||
assets = [ | ||
["target/release/cargo-deb", "usr/bin/ipmitool-dcmi-power-reading", "755"], | ||
["README.md", "usr/share/doc/ipmitool-dcmi-power-reading/README", "644"], | ||
] | ||
|
||
[dependencies] | ||
ipmi-rs = "0.2.1" | ||
pretty_env_logger = "0.4" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters