|
|
@ -5,29 +5,19 @@ set -euo pipefail |
|
|
|
# Wasmtime to crates.io. To use, bump the version number below, run the |
|
|
|
# script, and then run the commands that the script prints. |
|
|
|
|
|
|
|
topdir=$(dirname "$0") |
|
|
|
topdir=$(dirname "$0")/.. |
|
|
|
cd "$topdir" |
|
|
|
|
|
|
|
# All the wasmtime-* crates have the same version number |
|
|
|
version="0.2.0" |
|
|
|
|
|
|
|
# Update all of the Cargo.toml files. |
|
|
|
# |
|
|
|
# The main Cargo.toml in the top-level directory is the wasmtime crate which we don't publish. |
|
|
|
# Update the version numbers of the crates to $version. |
|
|
|
echo "Updating crate versions to $version" |
|
|
|
for crate in . wasmtime-*; do |
|
|
|
# Update the version number of this crate to $version. |
|
|
|
sed -i.bk -e "s/^version = .*/version = \"$version\"/" \ |
|
|
|
"$crate/Cargo.toml" |
|
|
|
|
|
|
|
# Update the required version number of any wasmtime* dependencies. |
|
|
|
sed -i.bk -e "/^wasmtime/s/version = \"[^\"]*\"/version = \"$version\"/" \ |
|
|
|
"$crate/Cargo.toml" |
|
|
|
done |
|
|
|
find -name Cargo.toml -exec sed -i.bk -e "s/^version = .*/version = \"$version\"/" {} \; |
|
|
|
|
|
|
|
# Update our local Cargo.lock (not checked in). |
|
|
|
cargo update |
|
|
|
./scripts/test-all.sh |
|
|
|
scripts/test-all.sh |
|
|
|
|
|
|
|
# Commands needed to publish. |
|
|
|
# |
|
|
@ -37,25 +27,4 @@ echo git commit -a -m "\"Bump version to $version"\" |
|
|
|
echo git tag v$version |
|
|
|
echo git push |
|
|
|
echo git push origin v$version |
|
|
|
for crate in \ |
|
|
|
wasmtime-environ \ |
|
|
|
wasmtime-debug \ |
|
|
|
wasmtime-runtime \ |
|
|
|
wasmtime-jit \ |
|
|
|
wasmtime-wast \ |
|
|
|
wasmtime-wasi \ |
|
|
|
wasmtime-wasi-c \ |
|
|
|
wasmtime-interface-types \ |
|
|
|
wasmtime-obj \ |
|
|
|
wasmtime-py \ |
|
|
|
wasmtime-rust \ |
|
|
|
wasmtime-cli \ |
|
|
|
wasi-common \ |
|
|
|
wasmtime |
|
|
|
do |
|
|
|
echo cargo publish --manifest-path "$crate/Cargo.toml" |
|
|
|
|
|
|
|
# Sleep for a few seconds to allow the server to update the index. |
|
|
|
# https://internals.rust-lang.org/t/changes-to-how-crates-io-handles-index-updates/9608 |
|
|
|
echo sleep 10 |
|
|
|
done |
|
|
|
echo "find -name Cargo.toml -exec scripts/cargo-chill.sh publish --manifest-path {} \\;" |
|
|
|