-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
43 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
|
||
$ARCH="x86_64" | ||
$PLATFORM="windows" | ||
|
||
$FEATURES="build_info" | ||
|
||
$ARCHIVE_DIR="$RELEASE_DIR/archive" | ||
$ARTIFACT_DIR="$RELEASE_DIR/artifact" | ||
|
||
|
||
# Compile application with features | ||
cargo build -p xmodits-gui --release --features=$FEATURES | ||
|
||
# Create artifact folder | ||
mkdir -Force -p "target/release/artifact" | ||
|
||
# Create archive folder | ||
mkdir -Force -p "target/release/archive" | ||
|
||
# move and rename xmodits-gui.exe to xmodits in archive folder | ||
mv -Force "target/release/xmodits-gui.exe" "target/release/archive/xmodits.exe" | ||
|
||
# Copy extras to archive folder | ||
cp -Force "README.md" "target/release/archive/" | ||
cp -Force "LICENSE" "target/release/archive/" | ||
|
||
# Get version number | ||
$VERSION = target/release/xmodits.exe --version | Out-String | ||
$VERSION = $VERSION.Trim() # trim whitespace, includes \n | ||
|
||
# Compress archive contents of archive folder to a zip file | ||
$ARTIFACT_PATH = "target/release/artifact/xmodits-gui-$VERSION-$PLATFORM-$ARCH.zip" | ||
Compress-Archive -Force -Path "target/release/archive/*" -DestinationPath $ARTIFACT_PATH | ||
|
||
echo "Packaged archive: $ARTIFACT_PATH" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters