2023-06-08 15:38:26 -04:00
|
|
|
#!/usr/bin/env bash
|
2022-11-18 23:33:54 -05:00
|
|
|
set -e
|
|
|
|
|
2023-02-18 09:36:12 -05:00
|
|
|
CWD="$(cd -P -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd -P)"
|
|
|
|
|
|
|
|
cd $CWD/../
|
|
|
|
|
2023-12-05 11:22:08 -05:00
|
|
|
cargo clippy --workspace --fix --allow-staged --allow-dirty --tests --all-targets --all-features -- -D warnings
|
2023-02-18 09:36:12 -05:00
|
|
|
|
2023-08-02 12:44:51 -04:00
|
|
|
# Format rust files
|
2023-02-18 09:36:12 -05:00
|
|
|
cargo +nightly fmt
|
2023-08-02 12:44:51 -04:00
|
|
|
|
|
|
|
# Format toml files
|
2023-07-14 04:45:18 -04:00
|
|
|
taplo format
|
2023-08-02 12:44:51 -04:00
|
|
|
|
|
|
|
# Format sql files
|
|
|
|
find migrations -type f -name '*.sql' -exec pg_format -i {} +
|