Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
nothingface0 committed Nov 16, 2023
1 parent 096a72f commit c5e72ca
Showing 1 changed file with 16 additions and 3 deletions.
19 changes: 16 additions & 3 deletions build_installation_package.sh
Original file line number Diff line number Diff line change
@@ -1,11 +1,24 @@
#!/bin/bash

# Script for creating a single compressed archive, after download_dependencies.sh
# Script for creating a single compressed deployment archive, once download_dependencies.sh
# has been executed.
# It will create an archive in the $TARGET_DIRECTORY, named $ARCHIVE_NAME.
# It will create an archive named $ARCHIVE_NAME using the files in $SOURCE_DIRECTORY,
# stored in $TARGET_DIRECTORY.

set -ex

SOURCE_DIRECTORY="."
TARGET_DIRECTORY="/tmp/dqmgui"
ARCHIVE_NAME="dqmgui_installation_package.tar.gz"

# Parse command line arguments -- use <key>=<value> to override the flags mentioned above.
# e.g. ARCHIVE_NAME="test.tar.gz"
for ARGUMENT in "$@"; do
KEY=$(echo "$ARGUMENT" | cut -f1 -d=)
KEY_LENGTH=${#KEY}
VALUE="${ARGUMENT:$KEY_LENGTH+1}"
eval "$KEY=$VALUE"
done

mkdir -p "$TARGET_DIRECTORY"
tar --exclude "./git" --exclude "./github" -cf "$TARGET_DIRECTORY/$ARCHIVE_NAME" . -I "gzip --best"
tar --exclude "./git" --exclude "./github" -cf "$TARGET_DIRECTORY/$ARCHIVE_NAME" "$SOURCE_DIRECTORY" -I "gzip --best"

0 comments on commit c5e72ca

Please sign in to comment.