build: Migrated from Makefile to justfile
Check / stable / fmt (push) Successful in 9m56s
Check / beta / clippy (push) Failing after 40s
Check / stable / clippy (push) Failing after 39s
Check / nightly / doc (push) Failing after 36s
Check / 1.89.0 / check (push) Failing after 39s
Test Suite / ubuntu / beta (push) Failing after 39s
Test Suite / ubuntu / stable (push) Failing after 38s
Test Suite / ubuntu / stable / coverage (push) Failing after 1m4s
Test Suite / macos-latest / stable (push) Has been cancelled
Test Suite / windows-latest / stable (push) Has been cancelled
Check / stable / fmt (push) Successful in 9m56s
Check / beta / clippy (push) Failing after 40s
Check / stable / clippy (push) Failing after 39s
Check / nightly / doc (push) Failing after 36s
Check / 1.89.0 / check (push) Failing after 39s
Test Suite / ubuntu / beta (push) Failing after 39s
Test Suite / ubuntu / stable (push) Failing after 38s
Test Suite / ubuntu / stable / coverage (push) Failing after 1m4s
Test Suite / macos-latest / stable (push) Has been cancelled
Test Suite / windows-latest / stable (push) Has been cancelled
This commit is contained in:
+2
-1
@@ -48,7 +48,8 @@ cz commit
|
||||
1. Clone this repo
|
||||
2. Run `cargo test` to set up hooks
|
||||
3. Make changes
|
||||
4. Run the application using `make run` or `cargo run`
|
||||
4. Run the application using `just run` or `just run`
|
||||
- Install `just` (`cargo install just`) if you haven't already to use the [justfile](./justfile) in this project.
|
||||
5. Commit changes. This will trigger pre-commit hooks that will run format, test and lint. If there are errors or
|
||||
warnings from Clippy, please fix them.
|
||||
6. Push your code to a new branch named after the feature/bug/etc. you're adding. This will trigger pre-push hooks that
|
||||
|
||||
@@ -1,40 +0,0 @@
|
||||
#!make
|
||||
default: run
|
||||
|
||||
.PHONY: test test-cov build run lint lint-fix fmt minimal-versions analyze release delete-tag
|
||||
|
||||
test:
|
||||
@cargo test --all
|
||||
|
||||
## Run all tests with coverage - `cargo install cargo-tarpaulin`
|
||||
test-cov:
|
||||
@cargo tarpaulin
|
||||
|
||||
build: test
|
||||
@cargo build --release
|
||||
|
||||
run:
|
||||
@CARGO_INCREMENTAL=1 cargo fmt && make lint && cargo run
|
||||
|
||||
lint:
|
||||
@find . | grep '\.\/src\/.*\.rs$$' | xargs touch && CARGO_INCREMENTAL=0 cargo clippy --all-targets --workspace
|
||||
|
||||
lint-fix:
|
||||
@cargo fix
|
||||
|
||||
fmt:
|
||||
@cargo fmt
|
||||
|
||||
minimal-versions:
|
||||
@cargo +nightly update -Zdirect-minimal-versions
|
||||
|
||||
## Analyze for unsafe usage - `cargo install cargo-geiger`
|
||||
analyze:
|
||||
@cargo geiger
|
||||
|
||||
release:
|
||||
@git tag -a ${V} -m "Release ${V}" && git push origin ${V}
|
||||
|
||||
delete-tag:
|
||||
@git tag -d ${V} && git push --delete origin ${V}
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
# List all recipes
|
||||
default:
|
||||
@just --list
|
||||
|
||||
# Format all files
|
||||
[group: 'style']
|
||||
fmt:
|
||||
@cargo fmt --all
|
||||
|
||||
alias clippy := lint
|
||||
# Run Clippy to inspect all files
|
||||
[group: 'style']
|
||||
lint:
|
||||
@cargo clippy --all
|
||||
|
||||
alias clippy-fix := lint-fix
|
||||
# Automatically fix clippy issues where possible
|
||||
[group: 'style']
|
||||
lint-fix:
|
||||
@cargo fix
|
||||
|
||||
# Run all tests
|
||||
[group: 'test']
|
||||
test:
|
||||
@cargo test --all
|
||||
|
||||
# Build and run the binary for the current system
|
||||
run:
|
||||
@cargo run
|
||||
|
||||
# Build the project for the current system architecture
|
||||
[group: 'build']
|
||||
[arg('build_type', pattern="debug|release")]
|
||||
build build_type='debug':
|
||||
@cargo build {{ if build_type == "release" { "--release" } else { "" } }}
|
||||
Reference in New Issue
Block a user