-
Notifications
You must be signed in to change notification settings - Fork 503
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into release-tags-only
- Loading branch information
Showing
1 changed file
with
12 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -61,15 +61,19 @@ check: actionlint fmt clippy test forbid | |
cargo ltest | ||
git checkout Cargo.lock | ||
|
||
publish-check: check man | ||
cargo outdated --root-deps-only --exit-code 1 | ||
|
||
# publish to crates.io and push release tag to github | ||
publish: publish-check | ||
git branch | grep '* master' | ||
git tag -a {{version}} -m 'Release {{version}}' | ||
git push github {{version}} | ||
# publish current GitHub master branch | ||
publish: | ||
#!/usr/bin/env bash | ||
set -euxo pipefail | ||
rm -rf tmp/release | ||
git clone [email protected]:casey/just.git tmp/release | ||
VERSION=`sed -En 's/version[[:space:]]*=[[:space:]]*"([^"]+)"/\1/p' Cargo.toml | head -1` | ||
cd tmp/release | ||
git tag -a $VERSION -m "Release $VERSION" | ||
git push github $VERSION | ||
cargo publish | ||
cd ../.. | ||
rm -rf tmp/release | ||
|
||
push: check | ||
! git branch | grep '* master' | ||
|