forked from GaloyMoney/cala
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
64 lines (48 loc) · 1.87 KB
/
Makefile
File metadata and controls
64 lines (48 loc) · 1.87 KB
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
next-watch:
cargo watch -s 'cargo nextest run'
clean-deps:
docker compose down
start-deps:
docker compose up -d integration-deps
setup-db:
cd cala-ledger && cargo sqlx migrate run
cd cala-server && cargo sqlx migrate run --ignore-missing
reset-deps: clean-deps start-deps setup-db
run-server:
cargo run --bin cala-server -- --config ./bats/cala.yml
rust-example:
cargo run --bin cala-ledger-example-rust
update-lib-in-nodejs-example:
cd cala-nodejs && SQLX_OFFLINE=true yarn build
cd examples/nodejs && rm -rf ./node_modules && yarn install
re-run-nodejs-example: clean-deps start-deps
sleep 2
cd examples/nodejs && yarn run start
check-code: sdl
git diff --exit-code cala-server/schema.graphql
SQLX_OFFLINE=true cargo fmt --check --all
SQLX_OFFLINE=true cargo check
SQLX_OFFLINE=true cargo clippy --package es-entity --all-features
SQLX_OFFLINE=true cargo clippy --package cala-server --features=
SQLX_OFFLINE=true cargo clippy --package cala-ledger --features="import,graphql"
SQLX_OFFLINE=true cargo clippy --package cala-ledger-core-types --features="graphql"
SQLX_OFFLINE=true cargo clippy --workspace --exclude es-entity --exclude cala-server --exclude cala-ledger --exclude cala-ledger-core-types
SQLX_OFFLINE=true cargo audit
SQLX_OFFLINE=true cargo deny check
build:
SQLX_OFFLINE=true cargo build --locked
e2e: clean-deps start-deps build
bats -t bats
sdl:
SQLX_OFFLINE=true cargo run --bin write_sdl > cala-server/schema.graphql
sqlx-prepare:
cd cala-ledger && cargo sqlx prepare -- --all-features
cd cala-server && cargo sqlx prepare -- --all-features
test-in-ci: start-deps setup-db
cargo nextest run --verbose --locked
cargo test --doc
cargo doc --no-deps
build-x86_64-unknown-linux-musl-release:
SQLX_OFFLINE=true cargo build --release --locked --bin cala-server --target x86_64-unknown-linux-musl
build-x86_64-apple-darwin-release:
bin/osxcross-compile.sh