Skip to content

Commit

Permalink
Fix 'just publish'
Browse files Browse the repository at this point in the history
Signed-off-by: Oliver Tale-Yazdi <[email protected]>
  • Loading branch information
ggwpez committed Feb 24, 2025
1 parent 112af65 commit ff1a426
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,12 @@ install:

publish:
#!/usr/bin/env bash
set -e
echo "Checking if crate can be published..."
VERSION=$(shell grep -E '^version = "[0-9.]+"' Cargo.toml | cut -d'"' -f2)
TAG=v$(VERSION)
echo "Publishing version '$(VERSION)' with tag '$(TAG)'"
VERSION=$(grep -E '^version = "[0-9.]+"' Cargo.toml | cut -d'"' -f2)
TAG="v${VERSION}"
echo "Publishing version '${VERSION}' with tag '${TAG}'"
echo "- Publishing crate to crates.io..."
echo " - Publishing core..."
cargo publish -p subweight-core --allow-dirty -q
Expand All @@ -27,7 +28,7 @@ publish:
echo " - Publishing web..."
cargo publish -p subweight-web --allow-dirty -q
echo "- Please sign the tag..."
git tag -s -a $(TAG) -m "Version $(VERSION)"
git tag -s -a "${TAG}" -m "Version ${VERSION}"
echo "- Pushing tag to GitHub..."
git push -f origin $(TAG)
git push -f origin "${TAG}"
echo "Done!"

0 comments on commit ff1a426

Please sign in to comment.