Skip to content

Commit

Permalink
Next release prep
Browse files Browse the repository at this point in the history
  • Loading branch information
atdixon committed Jan 29, 2023
1 parent 3c28c65 commit 442050e
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions scripts/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,11 @@ if [[ $(git status --porcelain) ]]; then
exit 1
fi

VERSION_CLJ_FILE="src/me/untethr/nostr/common/version.clj"

# safety - we want to fail (via set -e) if version.clj doesn't look like it
# restored from a previous release:
grep "\"SNAPSHOT\"" src/me/untethr/nostr/common/version.clj
grep "\"SNAPSHOT\"" "${VERSION_CLJ_FILE}"

read -rp 'Version: ' VERSION

Expand All @@ -31,13 +33,13 @@ git tag "v${VERSION}"
git push origin "v${VERSION}"

# probably non-os portable sed command (works on mac):
sed -i '' 's/"SNAPSHOT"/"'"${VERSION}"'"/g' src/me/untethr/nostr/common/version.clj
sed -i '' 's/"SNAPSHOT"/"'"${VERSION}"'"/g' "${VERSION_CLJ_FILE}"

make clean uberjar

mv target/me.untethr.nostr-relay.jar \
"target/me.untethr.nostr-relay-${VERSION}.jar"

git checkout -- src/me/untethr/nostr/version.clj
git checkout -- "${VERSION_CLJ_FILE}"

tar -czvf "target/me.untethr.nostr-relay-${VERSION}.tar.gz" conf/* -C target "me.untethr.nostr-relay-${VERSION}.jar"

0 comments on commit 442050e

Please sign in to comment.