chore: Add a script to manage crates

This commit is contained in:
Donny 2021-12-02 15:54:43 +09:00
parent d8c8641e59
commit b9baa503e3
2 changed files with 13 additions and 9 deletions

12
scripts/cargo/bump-with-cmd.sh Executable file
View File

@ -0,0 +1,12 @@
#!/usr/bin/env bash
set -eu
git pull || true
sh -c "$@"
# Ensure that Cargo.lock is up-to-date
cargo metadata --format-version 1 > /dev/null
git add -A
git commit -m 'chore: Publish crates'
git push
cargo mono publish --no-verify

View File

@ -1,12 +1,4 @@
#!/usr/bin/env bash
set -eu
git pull || true
cargo mono bump $@
# Ensure that Cargo.lock is up-to-date
cargo metadata --format-version 1 > /dev/null
git add -A
git commit -m 'chore: Publish crates'
git push
cargo mono publish --no-verify
./scripts/cargo/bump-with-cmd.sh "cargo mono bump $@"