Have Makefile that does same commands as CI
This commit is contained in:
parent
d38412a3bd
commit
31ed3963a6
2 changed files with 23 additions and 4 deletions
9
.github/workflows/ci.yml
vendored
9
.github/workflows/ci.yml
vendored
|
|
@ -9,6 +9,7 @@ on:
|
||||||
env:
|
env:
|
||||||
CARGO_TERM_COLOR: always
|
CARGO_TERM_COLOR: always
|
||||||
RUSTFLAGS: -Dwarnings
|
RUSTFLAGS: -Dwarnings
|
||||||
|
FEATURES: "logging,tls12"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
|
@ -19,10 +20,10 @@ jobs:
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: sudo apt-get install -y cmake clang
|
run: sudo apt-get install -y cmake clang
|
||||||
- name: Check fmt
|
- name: Check fmt
|
||||||
run: cargo fmt --all --check
|
run: make fmt
|
||||||
- name: Lint
|
- name: Lint
|
||||||
run: cargo clippy --workspace --all-targets -F "logging,tls12"
|
run: make lint
|
||||||
- name: Tests usual
|
- name: Tests usual
|
||||||
run: cargo test --all-targets -F "logging,tls12"
|
run: make test
|
||||||
- name: Build usual
|
- name: Build usual
|
||||||
run: cargo build --all-targets -F "logging,tls12"
|
run: make build
|
||||||
|
|
|
||||||
18
Makefile
Normal file
18
Makefile
Normal file
|
|
@ -0,0 +1,18 @@
|
||||||
|
FEATURES ?= logging,tls12
|
||||||
|
|
||||||
|
|
||||||
|
.PHONY: fmt
|
||||||
|
fmt:
|
||||||
|
cargo fmt --all --check
|
||||||
|
|
||||||
|
.PHONY: lint
|
||||||
|
lint:
|
||||||
|
cargo clippy --workspace --all-targets -F "$(FEATURES)"
|
||||||
|
|
||||||
|
.PHONY: test
|
||||||
|
test:
|
||||||
|
cargo test --all-targets -F "$(FEATURES)"
|
||||||
|
|
||||||
|
.PHONY: build
|
||||||
|
build:
|
||||||
|
cargo build --all-targets -F "$(FEATURES)"
|
||||||
Loading…
Add table
Add a link
Reference in a new issue