diff --git a/crates/html-generator/Cargo.toml b/crates/html-generator/Cargo.toml index 11a3c6d..a6baf9c 100644 --- a/crates/html-generator/Cargo.toml +++ b/crates/html-generator/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "html-generator" -version = "0.1.0" +version = "0.0.1-alpha" edition = "2021" description = "A simple library to generate html content with a simple way." # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/crates/metassr-build/Cargo.toml b/crates/metassr-build/Cargo.toml index 7747390..1c53d26 100644 --- a/crates/metassr-build/Cargo.toml +++ b/crates/metassr-build/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "metassr-build" -version = "0.1.0" +version = "0.0.1-alpha" edition = "2021" description = "Web builder & client bundler (built on Rspack), built for MetaSSR." # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/crates/metassr-create/Cargo.toml b/crates/metassr-create/Cargo.toml index 29b4e12..723a8b6 100644 --- a/crates/metassr-create/Cargo.toml +++ b/crates/metassr-create/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "metassr-create" -version = "0.1.0" +version = "0.0.1-alpha" edition = "2021" build = "build.rs" diff --git a/crates/metassr-utils/Cargo.toml b/crates/metassr-utils/Cargo.toml index 751b473..a71d642 100644 --- a/crates/metassr-utils/Cargo.toml +++ b/crates/metassr-utils/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "metassr-utils" -version = "0.1.0" +version = "0.0.1-alpha" edition = "2021" description = "Important utilites for MetaSSR" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/metassr-cli/Cargo.toml b/metassr-cli/Cargo.toml index 47901d7..5b2bba1 100644 --- a/metassr-cli/Cargo.toml +++ b/metassr-cli/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "metassr-cli" -version = "0.1.0-alpha" +version = "0.0.1-alpha" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/scripts/bump-version.sh b/scripts/bump-version.sh new file mode 100755 index 0000000..9533773 --- /dev/null +++ b/scripts/bump-version.sh @@ -0,0 +1,22 @@ +#!/bin/bash + +if [ $# -ne 1 ]; then + echo "Usage: $0 " + exit 1 +fi + +NEW_VERSION=$1 + +update_version() { + local file=$1 + echo "Updating version in $file to $NEW_VERSION" + # Use `sed` to find and replace the version in the Cargo.toml file + sed -i -E "s/^version = \"[^\"]+\"/version = \"$NEW_VERSION\"/" "$file" +} + +# Find all Cargo.toml files and update their versions +find . -name 'Cargo.toml' -print0 | while IFS= read -r -d '' file; do + update_version "$file" +done + +echo "Version update completed."