This script will vendor the Rust dependencies of the app so that our tarballs can be built offline.
9 lines
237 B
Bash
9 lines
237 B
Bash
#!/bin/sh
|
|
export DIST="$1"
|
|
export SOURCE_ROOT="$2"
|
|
|
|
cd "$SOURCE_ROOT"
|
|
mkdir "$DIST"/.cargo
|
|
cargo vendor | sed 's/^directory = ".*"/directory = "vendor"/g' > $DIST/.cargo/config
|
|
# Move vendor into dist tarball directory
|
|
mv vendor "$DIST"
|