openspades/Resources/downloadpak.sh
Tomoaki Kawada d26471d513 Update *.sh to use bash
Fixes #431.
2016-11-11 04:07:08 +09:00

25 lines
698 B
Bash
Executable File

#!/usr/bin/env bash
# This script downloads proprietary part of official .paks.
#
# note: the proprietary part contains following files:
#
# 1. sound files based on commercial sound libraries. Individual redistri-
# bution of such files are disallowed by the publishers of sound libraries
# (thus must be bundled with a software).
#
# 2. kv6 files from the original AoS 0.75.
SRC_DIR="`dirname "$0"`"
PAK_URL=$(grep --max-count=1 --no-filename --context=0 --color=never \
"DevPaks" "$SRC_DIR/PakLocation.txt")
PAK_NAME=$(basename "$PAK_URL")
OUTPUT_DIR="."
if [ -f "$PAK_NAME" ]; then
exit 0
fi
wget "$PAK_URL" -O "$PAK_NAME"
unzip -u -o "$PAK_NAME" -d "$OUTPUT_DIR"