1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-18 17:23:37 +00:00

Change Powershell compress script to bash (#14107)

This commit is contained in:
Vince Grassia
2025-04-03 08:22:32 -07:00
committed by GitHub
parent 960b77ddd7
commit 2ceb8272b7
2 changed files with 36 additions and 4 deletions

View File

@@ -0,0 +1,32 @@
#!/usr/bin/env bash
####
# Compress the build directory into a zip file.
####
set -e
set -u
set -x
set -o pipefail
FILENAME=$1
SCRIPT_ROOT="$(dirname "$0")"
BUILD_DIR="$SCRIPT_ROOT/../build"
# Check if build directory exists
if [ -d "$BUILD_DIR" ]; then
cd $BUILD_DIR
# Create dist directory if it doesn't exist
DIST_DIR="../dist"
mkdir -p $DIST_DIR
# Remove existing dist zip file
DIST_PATH="$DIST_DIR/$FILENAME"
rm -f $DIST_PATH
# Compress build directory
zip -r $DIST_PATH ./
echo "Zipped $BUILD_DIR into $DIST_PATH"
fi