Skip to content

Commit 0feb4e5

Browse files
committed
fiXeS tHE ReLEAsE
1 parent 42eafb8 commit 0feb4e5

2 files changed

Lines changed: 4 additions & 8 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

release.sh

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,9 @@ bump_major() {
3232
echo "${parts[0]}.${parts[1]}.${parts[2]}"
3333
}
3434

35-
# Get the current version
3635
current_version=$(get_version)
3736
echo "Current version: $current_version"
3837

39-
# Check the argument for which version to bump
4038
if [ "$1" == "bump_patch" ]; then
4139
new_version=$(bump_patch "$current_version")
4240
elif [ "$1" == "bump_minor" ]; then
@@ -50,17 +48,15 @@ fi
5048

5149
echo "New version: $new_version"
5250

53-
# Update the version in Cargo.toml
54-
sed -i'' -E "s/^version = \"$current_version\"/version = \"$new_version\"/" Cargo.toml
51+
sed -i'' -E "s/^version = \"$current_version\"/version = \"$new_version\"/" Cargo.toml || sed -i -E "s/^version = \"$current_version\"/version = \"$new_version\"/" Cargo.toml
5552

56-
# Commit the changes to Cargo.toml
5753
git add Cargo.toml
54+
git add Cargo.lock
55+
5856
git commit -m "Bump version to $new_version"
5957

60-
# Tag the new version
6158
git tag "v$new_version"
6259

63-
# Push the changes and the tags
6460
git push origin main
6561
git push origin "v$new_version"
6662

0 commit comments

Comments
 (0)