summaryrefslogtreecommitdiff
path: root/scripts/release.sh
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/release.sh')
-rwxr-xr-xscripts/release.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/scripts/release.sh b/scripts/release.sh
new file mode 100755
index 0000000..9c513f4
--- /dev/null
+++ b/scripts/release.sh
@@ -0,0 +1,10 @@
+if [ $# -eq 0 ]; then
+ echo "You must pass the version number."
+ exit 1
+fi
+
+sed -i "3s/.*/version = \"$1\"/" Cargo.toml
+cargo c
+git add Cargo.*
+git commit -m "release: version $1"
+git tag -a "v$1" -m "Version $1"