pbe/generate-release-artifacts.sh
Gered e4aa4afcec improvements to generate-release-artifacts.sh
- better filename for the generated archive
- clean before build, always feels like a good idea
- always be sure to include the example site files, instead of doing it
  manually, post-run as i was doing before (and forgot to do for one
  of the releases ... oops ...)
2023-07-11 13:00:08 -04:00

23 lines
540 B
Bash
Executable file

#!/bin/bash
cd "$(dirname "$0")"
package_version=$(cargo pkgid | cut -d# -f2 | cut -d: -f2)
current_target=$(rustc -vV | sed -n 's|host: ||p')
package_filename="pbe-v${package_version}-${current_target}.tar.gz"
rm -f ./artifacts/bin/pbe
rm -f ./artifacts/bin/syntax_to_css
cargo clean
cargo install --path . --root ./artifacts/
cargo install --path ./syntax_to_css/ --root ./artifacts/
tar -cvf $package_filename \
example-site \
-C ./artifacts/bin \
pbe \
syntax_to_css
echo "Packaged release as ${package_filename}"