-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjustfile
71 lines (51 loc) · 1.53 KB
/
justfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
set dotenv-load := true
alias v := verify
alias r := run
image_name := "ghcr.io/optravis-llc/qwit-cli"
bt := '0'
log := "warn"
@_list:
just --list --unsorted
run:
cargo run
install:
cargo install --path .
# Perform all verifications (compile, test, lint, etc.)
@verify: test lint
echo ------------ verify done! ------------
# Watch the source files and run `just verify` when source changes
watch:
cargo watch -- just verify
# Run the tests
test:
cargo hack test --feature-powerset
# Run the static code analysis
lint:
cargo fmt --all -- --check
cargo hack clippy --feature-powerset --all-targets --workspace
# Install cargo dev-tools used by the `verify` recipe (requires rustup to be already installed)
# you may need to install perl IPC cmd "yum install perl-IPC-Cmd" and install the perl module "cpan install File::Remote"
install-dev-tools:
rustup install stable
rustup override set stable
cargo install cargo-hack cargo-watch cargo-deny
cargo install cargo-release
clean:
rm -rf target
rm -f Cargo.lock
rm -rf node_modules
fmt:
cargo fmt
pub:
cargo publish
# latest doc file
create-doc: install
qwit markdown > DOC.md
release *args: verify
test $GITHUB_TOKEN
test $CARGO_REGISTRY_TOKEN
cargo release {{args}}
# example how to run it, you need to build it first obv.
run-docker:
cd distributions && just build-docker
docker run --rm -v ./testfiles/tmp/test.csv:/testfiles/tmp/test.csv -t {{image_name}}:latest show --source testfiles/tmp/test.csv