Skip to content

Commit

Permalink
fix(ci): 🐛 Make compressed files with binaries for each os
Browse files Browse the repository at this point in the history
  • Loading branch information
SpiralOutDotEu committed Nov 3, 2023
1 parent dab16b6 commit b63e253
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion update_version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,20 @@ rm $CARGO_TOML.bak
rm $CARGO_LOCK.bak

# Build the project with the updated version number
cargo build --target x86_64-unknown-linux-gnu --release

# Prepare for multi-os build
sudo apt-get install podman
cargo install cross

# For Linux
cargo build --target x86_64-unknown-linux-gnu --release
tar -czvf zk_whitelist_linux.tar.gz -C target/x86_64-unknown-linux-gnu/release/ zk_whitelist

# Build for Windows
rustup target add x86_64-pc-windows-gnu
cross build --target x86_64-pc-windows-gnu --release
zip zk_whitelist_windows.zip -j target/x86_64-pc-windows-gnu/release/zk_whitelist.exe


# build for Mac
curl -L https://github.com/roblabla/MacOSX-SDKs/releases/download/13.3/MacOSX13.3.sdk.tar.xz | tar xJ
Expand All @@ -34,4 +39,5 @@ export PATH=$PATH:~/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustl
export CARGO_TARGET_X86_64_APPLE_DARWIN_LINKER=rust-lld
rustup target add x86_64-apple-darwin
cargo build --release --target x86_64-apple-darwin
tar -czvf zk_whitelist_macos.tar.gz -C target/x86_64-apple-darwin/release/ zk_whitelist

0 comments on commit b63e253

Please sign in to comment.