Skip to content

Commit

Permalink
👷 Update Makefile (to replace justfile)
Browse files Browse the repository at this point in the history
- remove `--locked`, no command to generate .lock, .lock should not be committed for a lib, and check with .lock is dangerous for a lib
- add `generate` target
- add `test` target

Signed-off-by: David Bernard <david.bernard.31@gmail.com>
  • Loading branch information
davidB committed Jan 23, 2024
1 parent 6c9ccc9 commit 0c20047
Showing 1 changed file with 18 additions and 10 deletions.
28 changes: 18 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
build_docs:
cargo doc --locked --no-deps
cargo doc --no-deps
build_examples:
cargo --locked build --examples
cargo build --examples
build:
cargo build --locked
cargo build
build_release:
cargo --locked build --release
cargo build --release
build_release_%:
cargo --locked build --release --package $*
cargo build --release --package $*
build_%:
cargo build --locked --package $*
cargo build --package $*

check:
cargo check --locked
cargo check
check_no_std:
cargo --version
cargo check --locked --target thumbv7em-none-eabihf -p ockam --no-default-features --features 'no_std alloc software_vault'
cargo check --target thumbv7em-none-eabihf -p ockam --no-default-features --features 'no_std alloc software_vault'
# no_std example project
cd examples/rust/example_projects/no_std
cargo check --example hello
Expand All @@ -24,7 +24,7 @@ check_cargo_update:
# TODO: uncomment when tauri version is updated
# rm -rf Cargo.lock
# cargo update
# cargo check --locked
# cargo check

lint: lint_cargo_fmt_check lint_cargo_deny lint_cargo_clippy

Expand Down Expand Up @@ -53,7 +53,15 @@ very_clean:
format:
cargo fmt --all

generate:
cargo run -p generator -- --templates-dir "generator/templates" --jsonschema-dir "cdevents-spec/schemas" --dest "cdevents-sdk/src/generated"

test:
cargo nextest run
cargo test --doc

.PHONY:
check \
generate \
check test \
lint lint_cargo_fmt_check lint_cargo_deny lint_cargo_clippy lint_cargo_toml_files lint_cargo_readme lint_cargo_readme_% lint_cargo_toml_files \
clean clean_% very_clean format

0 comments on commit 0c20047

Please sign in to comment.