aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authoroldmud0 <oldmud0@users.noreply.github.com>2019-04-03 16:12:31 -0500
committeroldmud0 <oldmud0@users.noreply.github.com>2019-04-03 16:12:31 -0500
commit4561f1809feb16dff449daa972466e3ed2dfe494 (patch)
tree96e70ba108422cddad1a1357527d0bcce2c7e55a /scripts
parentedb3c6b538e80c08595baf71d32356bf0cf97795 (diff)
Fix some bugs in manifest script
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/update_manifest.js5
-rwxr-xr-xscripts/wasabi.sh11
2 files changed, 10 insertions, 6 deletions
diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js
index 66df75f0..ea1f85e6 100755
--- a/scripts/update_manifest.js
+++ b/scripts/update_manifest.js
@@ -41,9 +41,10 @@ const {
manifestFile,
version,
fullZipFile,
- incremental: [incrementalZipFile, deletionsFile],
+ incremental,
executable
} = argParser.parseArgs();
+const [incrementalZipFile, deletionsFile] = incremental || [];
const manifest = JSON.parse(fs.readFileSync(manifestFile));
@@ -60,7 +61,7 @@ const urlBase = "https://s3.wasabisys.com/ao-downloads/";
manifest.versions = [{
version,
executable,
- prev: manifest.version[0] ? manifest.version[0].version : undefined,
+ prev: manifest.versions[0] ? manifest.versions[0].version : undefined,
full: fullZipFile ? [
{
action: "dl",
diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh
index 52006526..2e8932d9 100755
--- a/scripts/wasabi.sh
+++ b/scripts/wasabi.sh
@@ -8,6 +8,7 @@
# ARCHIVE_FULL: name of the full archive (if desired)
# ARCHIVE_INCR: name of the incremental archive (if desired)
# VERSION: name of the new version
+# EXECUTABLE: name of the executable (if program manifest)
# -E: inherit ERR trap by shell functions
@@ -25,11 +26,9 @@ export S3_COPY="aws s3 cp --endpoint-url=https://s3.wasabisys.com"
export S3_MANIFESTS="s3://ao-manifests"
export S3_ARCHIVES="s3://ao-downloads"
-#export VERSION=$(git describe --tags)
-#export ARCHIVE_FULL="vanilla_full_${VERSION}_${ARTIFACT_SUFFIX}"
export ARCHIVE_FULL_ARG=""
-#export ARCHIVE_INCR="vanilla_update_${VERSION}_${ARTIFACT_SUFFIX}"
export ARCHIVE_INCR_ARG=""
+export EXECUTABLE_ARG=""
export LAST_TAGGED_VERSION=$(git rev-list --tags --skip=1 --max-count=1)
echo "Previous tagged version: ${LAST_TAGGED_VERSION}"
@@ -57,9 +56,13 @@ if [[ -n $ARCHIVE_FULL ]]; then
export ARCHIVE_FULL_ARG="-f ${ARCHIVE_FULL}"
fi
+if [[ -n $EXECUTABLE ]]; then
+ export EXECUTABLE_ARG="-e ${EXECUTABLE}"
+fi
+
${S3_COPY} ${S3_MANIFESTS}/${MANIFEST} .
node $(dirname $0)/update_manifest.js ${MANIFEST} ${VERSION} \
- ${ARCHIVE_FULL_ARG} ${ARCHIVE_INCR_ARG}
+ ${ARCHIVE_FULL_ARG} ${ARCHIVE_INCR_ARG} ${EXECUTABLE}
if [[ -n $ARCHIVE_INCR_ARG ]]; then
${S3_COPY} ${ARCHIVE_INCR} ${S3_ARCHIVES}