chore: add publish script for urdf and stl + unify all releases by de… (#727)
* chore: add publish script for urdf and stl + unify all releases by default * better cross platform publish support * publish in dry run within ci * publish scripts better errors, abort if a publish fails, with an exit code. * chore(rapier_urdf): fix warnings * chore(rapier-urdf): typo fix --------- Co-authored-by: Sébastien Crozet <developer@crozet.re>
This commit is contained in:
35
scripts/publish-rapier.sh
Executable file
35
scripts/publish-rapier.sh
Executable file
@@ -0,0 +1,35 @@
|
||||
#!/bin/bash
|
||||
|
||||
tmp=$(mktemp -d)
|
||||
|
||||
echo "$tmp"
|
||||
|
||||
cp -r src "$tmp"/.
|
||||
cp -r LICENSE README.md "$tmp"/.
|
||||
|
||||
### Publish the 2D version.
|
||||
sed 's#\.\./\.\./src#src#g' crates/rapier2d/Cargo.toml > "$tmp"/Cargo.toml
|
||||
currdir=$(pwd)
|
||||
cd "$tmp" && cargo publish $DRY_RUN || exit 1
|
||||
cd "$currdir" || exit 2
|
||||
|
||||
|
||||
### Publish the 3D version.
|
||||
sed 's#\.\./\.\./src#src#g' crates/rapier3d/Cargo.toml > "$tmp"/Cargo.toml
|
||||
cp -r LICENSE README.md "$tmp"/.
|
||||
cd "$tmp" && cargo publish $DRY_RUN || exit 1
|
||||
cd "$currdir" || exit 2
|
||||
|
||||
### Publish the 2D f64 version.
|
||||
sed 's#\.\./\.\./src#src#g' crates/rapier2d-f64/Cargo.toml > "$tmp"/Cargo.toml
|
||||
currdir=$(pwd)
|
||||
cd "$tmp" && cargo publish $DRY_RUN || exit 1
|
||||
cd "$currdir" || exit 2
|
||||
|
||||
|
||||
### Publish the 3D f64 version.
|
||||
sed 's#\.\./\.\./src#src#g' crates/rapier3d-f64/Cargo.toml > "$tmp"/Cargo.toml
|
||||
cp -r LICENSE README.md "$tmp"/.
|
||||
cd "$tmp" && cargo publish $DRY_RUN || exit 1
|
||||
|
||||
rm -rf "$tmp"
|
||||
Reference in New Issue
Block a user