From 6261be1dc82e3f113a0392c2cf93449d784cfb08 Mon Sep 17 00:00:00 2001 From: oldmud0 <3421260-oldmud0@users.noreply.gitlab.com> Date: Sun, 10 Feb 2019 01:04:28 +0000 Subject: Add Travis script for Mac builds --- scripts/macos_build.sh | 30 ++++++++++++++++++++++++++++++ scripts/macos_post_build.sh | 2 -- 2 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 scripts/macos_build.sh (limited to 'scripts') diff --git a/scripts/macos_build.sh b/scripts/macos_build.sh new file mode 100644 index 00000000..150c3383 --- /dev/null +++ b/scripts/macos_build.sh @@ -0,0 +1,30 @@ +#!/bin/sh + +set -Eeuxo pipefail + +export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig +export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/opt/openssl/lib/pkgconfig +export PATH=$PATH:/usr/local/opt/qt5/bin:/usr/local/bin + +mkdir bass +cd bass +curl http://www.un4seen.com/files/bass24-osx.zip -o bass.zip +unzip bass.zip +cp libbass.dylib ../lib +cd .. + +mkdir discord-rpc +cd discord-rpc +curl -L https://github.com/discordapp/discord-rpc/releases/download/v3.4.0/discord-rpc-osx.zip +unzip discord_rpc_osx.zip +cp discord-rpc/osx-dynamic/lib/libdiscord-rpc.a ../lib +cd .. + +mkdir qtapng +cd qtapng +curl -L https://github.com/Skycoder42/QtApng/releases/download/1.1.0-5/build_clang_64_5.12.0.tar.xz -o apng.tar.xz +tar -xvf apng.tar.xz +cp clang_64/plugins/imageformats/libqapng.dylib ../lib +cd .. + +qmake && make -j2 diff --git a/scripts/macos_post_build.sh b/scripts/macos_post_build.sh index d69da0b4..700361ef 100644 --- a/scripts/macos_post_build.sh +++ b/scripts/macos_post_build.sh @@ -2,8 +2,6 @@ DST_FOLDER="./bin/Attorney_Online.app/Contents/Frameworks" -cd .. - mkdir $DST_FOLDER cp ./lib/libbass.dylib $DST_FOLDER -- cgit From f23d163a277f8546953c2f5c3e334d2e09ec21f6 Mon Sep 17 00:00:00 2001 From: oldmud0 <3421260-oldmud0@users.noreply.gitlab.com> Date: Sun, 10 Feb 2019 01:52:16 +0000 Subject: Okay, let's try this again... --- scripts/macos_build.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'scripts') diff --git a/scripts/macos_build.sh b/scripts/macos_build.sh index 150c3383..86605c5a 100644 --- a/scripts/macos_build.sh +++ b/scripts/macos_build.sh @@ -1,9 +1,8 @@ #!/bin/sh -set -Eeuxo pipefail +set -Eexo pipefail -export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig -export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/opt/openssl/lib/pkgconfig +export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig:/usr/local/opt/openssl/lib/pkgconfig export PATH=$PATH:/usr/local/opt/qt5/bin:/usr/local/bin mkdir bass -- cgit From 200008fd81d305ea1641e4b643119071dc3a08a7 Mon Sep 17 00:00:00 2001 From: oldmud0 <3421260-oldmud0@users.noreply.gitlab.com> Date: Sun, 10 Feb 2019 02:00:13 +0000 Subject: Actually save the discord-rpc zip --- scripts/macos_build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/macos_build.sh b/scripts/macos_build.sh index 86605c5a..efe0f7cd 100644 --- a/scripts/macos_build.sh +++ b/scripts/macos_build.sh @@ -14,7 +14,7 @@ cd .. mkdir discord-rpc cd discord-rpc -curl -L https://github.com/discordapp/discord-rpc/releases/download/v3.4.0/discord-rpc-osx.zip +curl -L https://github.com/discordapp/discord-rpc/releases/download/v3.4.0/discord-rpc-osx.zip -o discord_rpc_osx.zip unzip discord_rpc_osx.zip cp discord-rpc/osx-dynamic/lib/libdiscord-rpc.a ../lib cd .. -- cgit From f05c3defcfc1cd64147c2f3c7de0ca3c44140050 Mon Sep 17 00:00:00 2001 From: oldmud0 <3421260-oldmud0@users.noreply.gitlab.com> Date: Sun, 10 Feb 2019 02:08:48 +0000 Subject: Keep fixing issues with the Mac build script --- scripts/macos_build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/macos_build.sh b/scripts/macos_build.sh index efe0f7cd..ebe93d32 100644 --- a/scripts/macos_build.sh +++ b/scripts/macos_build.sh @@ -16,7 +16,7 @@ mkdir discord-rpc cd discord-rpc curl -L https://github.com/discordapp/discord-rpc/releases/download/v3.4.0/discord-rpc-osx.zip -o discord_rpc_osx.zip unzip discord_rpc_osx.zip -cp discord-rpc/osx-dynamic/lib/libdiscord-rpc.a ../lib +cp discord-rpc/osx-static/lib/libdiscord-rpc.a ../lib cd .. mkdir qtapng -- cgit From 9a32aa6e849cab35710aaddd5e2323276e8eccfb Mon Sep 17 00:00:00 2001 From: oldmud0 <3421260-oldmud0@users.noreply.gitlab.com> Date: Sun, 10 Feb 2019 02:45:10 +0000 Subject: Add BASSOPUS to all target platforms --- scripts/macos_build.sh | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'scripts') diff --git a/scripts/macos_build.sh b/scripts/macos_build.sh index ebe93d32..22e2d457 100644 --- a/scripts/macos_build.sh +++ b/scripts/macos_build.sh @@ -10,6 +10,10 @@ cd bass curl http://www.un4seen.com/files/bass24-osx.zip -o bass.zip unzip bass.zip cp libbass.dylib ../lib + +curl http://www.un4seen.com/files/bassopus24-osx.zip -o bassopus.zip +unzip bassopus.zip +cp libbassopus.dylib ../lib cd .. mkdir discord-rpc -- cgit From 5d0044b93cfd5ada490c7c1b296bdd0f1602a8f2 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Fri, 29 Mar 2019 21:03:43 -0500 Subject: Add a bunch of scripts --- scripts/macos_build.sh | 0 scripts/macos_post_build.sh | 0 scripts/package.json | 9 ++++ scripts/update_manifest.js | 84 ++++++++++++++++++++++++++++++++++++++ scripts/update_program_manifest.js | 39 ++++++++++++++++++ scripts/wasabi_asset.sh | 45 ++++++++++++++++++++ scripts/wasabi_program.sh | 35 ++++++++++++++++ scripts/windows/Dockerfile | 17 ++++++++ scripts/windows/Dockerfile-mxe | 44 ++++++++++++++++++++ scripts/windows/how-to-push.md | 19 +++++++++ 10 files changed, 292 insertions(+) mode change 100644 => 100755 scripts/macos_build.sh mode change 100644 => 100755 scripts/macos_post_build.sh create mode 100644 scripts/package.json create mode 100755 scripts/update_manifest.js create mode 100755 scripts/update_program_manifest.js create mode 100755 scripts/wasabi_asset.sh create mode 100755 scripts/wasabi_program.sh create mode 100644 scripts/windows/Dockerfile create mode 100644 scripts/windows/Dockerfile-mxe create mode 100644 scripts/windows/how-to-push.md (limited to 'scripts') diff --git a/scripts/macos_build.sh b/scripts/macos_build.sh old mode 100644 new mode 100755 diff --git a/scripts/macos_post_build.sh b/scripts/macos_post_build.sh old mode 100644 new mode 100755 diff --git a/scripts/package.json b/scripts/package.json new file mode 100644 index 00000000..126a3920 --- /dev/null +++ b/scripts/package.json @@ -0,0 +1,9 @@ +{ + "name": "ao-ci-scripts", + "version": "1.0.0", + "main": "update_manifest.js", + "dependencies": { + "argparse": "^1.0.10" + }, + "license": "ISC" +} diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js new file mode 100755 index 00000000..5f64cfb4 --- /dev/null +++ b/scripts/update_manifest.js @@ -0,0 +1,84 @@ +#!/usr/bin/env node + +const fs = require("fs"); +const crypto = require("crypto"); +const ArgumentParser = require("argparse").ArgumentParser; + +function isFile(file) { + if (!fs.existsSync(file)) { + console.error(`File '${file}' not found. Try again.`); + throw Error(); + } + return file; +} + +const argParser = new ArgumentParser({ + addHelp: true, + description: "Adds a new latest version to the manifest file based on the " + + "provided zip file, including an incremental update." +}); +argParser.addArgument("manifestFile", { + metavar: "", type: isFile +}); +argParser.addArgument("version", { + metavar: "" +}); +argParser.addArgument([ "-f", "--full" ], { + metavar: "", type: isFile, nargs: 1, + dest: "fullZipFile" +}); +argParser.addArgument([ "-i", "--incremental" ], { + type: isFile, nargs: 2, dest: "incremental", + metavar: ["", ""] +}); +argParser.addArgument([ "-e", "--executable" ], { + metavar: "[executable file]", nargs: 1, + dest: "executable" +}); + +const { + manifestFile, + version, + fullZipFile, + incremental: [incrementalZipFile, deletionsFile], + executable +} = argParser.parseArgs(); + +const manifest = JSON.parse(fs.readFileSync(manifestFile)); + +const deleteActions = deletionsFile ? fs.readFileSync(deletionsFile) + .split("\n").map(file => { + // XXX: This does not delete empty directories. Finding them would + // actually be a substantial amount of work because Git does not + // give us a good way of finding directories that were deleted. + return { action: "delete", target: file }; + }) : []; + +const urlBase = "https://s3.wasabisys.com/ao-downloads/"; + +manifest.versions = [{ + version, + executable, + prev: manifest.version[0] ? manifest.version[0].version : undefined, + full: fullZipFile ? [ + { + action: "dl", + url: urlBase + encodeURIComponent(fullZipFile), + hash: crypto.createHash("sha1") + .update(fs.readFileSync(fullZipFile)) + .digest("hex") + } + ] : undefined, + update: incremental ? [ + ...deleteActions, + { + action: "dl", + url: urlBase + encodeURIComponent(incrementalZipFile), + hash: crypto.createHash("sha1") + .update(fs.readFileSync(incrementalZipFile)) + .digest("hex") + } + ] : undefined +}, ...manifest.versions]; + +fs.writeFileSync(manifestFile, JSON.stringify(manifest, null, 4)); diff --git a/scripts/update_program_manifest.js b/scripts/update_program_manifest.js new file mode 100755 index 00000000..9efc814f --- /dev/null +++ b/scripts/update_program_manifest.js @@ -0,0 +1,39 @@ +#!/usr/bin/env node + +const fs = require("fs"); +const crypto = require("crypto"); + +const [ _nodeExe, _jsPath, manifestFile, version, zipFile ] = process.argv; + +if (!manifestFile || !version || !zipFile) { + console.log(`Usage: update_program_manifest `); + console.log(`Adds a new latest version to the manifest file based on the ` + + `provided zip file.`); + process.exit(1); +} + +if (!fs.existsSync(manifestFile)) { + console.error(`Manifest file '${manifestFile}' not found. Try again.`); + process.exit(2); +} + +if (!fs.existsSync(zipFile)) { + console.error(`Zip file '${zipFile}' not found. Try again.`); + process.exit(2); +} + +const manifest = JSON.parse(fs.readFileSync(manifestFile)); + +manifest.versions = [{ + version, + executable: "Attorney_Online.exe", + full: [ + { + action: "dl", + url: "https://s3.wasabisys.com/ao-downloads/" + encodeURIComponent(zipFile), + hash: crypto.createHash("sha1").update(fs.readFileSync(zipFile)).digest("hex") + } + ] +}, ...manifest.versions]; + +fs.writeFileSync(manifestFile, JSON.stringify(manifest, null, 4)); \ No newline at end of file diff --git a/scripts/wasabi_asset.sh b/scripts/wasabi_asset.sh new file mode 100755 index 00000000..d424183a --- /dev/null +++ b/scripts/wasabi_asset.sh @@ -0,0 +1,45 @@ +#!/bin/bash +# Updates the specified program manifest to a new archive and version +# and uploads the new archive and manifest to S3/Wasabi. +# +# Requires: +# MANIFEST: name of the manifest file +# ARTIFACT_SUFFIX: suffix of the archive to be uploaded (including extension) +# S3_ACCESS_KEY and S3_SECRET_KEY + + +# -E: inherit ERR trap by shell functions +# -e: stop script on ERR trap +# -u: stop script on unbound variables +# -x: print command before running it +# -o pipefail: fail if any command in a pipeline fails +set -Eeuxo pipefail + +aws configure set aws_access_key_id ${S3_ACCESS_KEY} +aws configure set aws_secret_access_key ${S3_SECRET_KEY} +aws configure set default.region us-east-1 + +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_INCR="vanilla_update_${VERSION}_${ARTIFACT_SUFFIX}" + +git log --diff-filter=D --summary $(git rev-list --tags --skip=1 --max-count=1)..HEAD | \ + grep "delete mode" | cut -d' ' -f 5- > deletions.txt + +${S3_COPY} ${S3_MANIFESTS}/${MANIFEST} . +if [[ -n FULL_ZIP && FULL_ZIP != '0' ]]; then + node $(dirname $0)/update_manifest.js ${MANIFEST} ${VERSION} + -f ${ARCHIVE_FULL} -i ${ARCHIVE_INCR} deletions.txt + ${S3_COPY} ${ARCHIVE_FULL} ${S3_ARCHIVES} +else + node $(dirname $0)/update_manifest.js ${MANIFEST} ${VERSION} + -i ${ARCHIVE_INCR} deletions.txt +fi +${S3_COPY} ${ARCHIVE_INCR} ${S3_ARCHIVES} +${S3_COPY} ${MANIFEST} ${S3_MANIFESTS} + +rm -f ${MANIFEST} diff --git a/scripts/wasabi_program.sh b/scripts/wasabi_program.sh new file mode 100755 index 00000000..41e2e352 --- /dev/null +++ b/scripts/wasabi_program.sh @@ -0,0 +1,35 @@ +#!/bin/sh +# Updates the specified program manifest to a new archive and version +# and uploads the new archive and manifest to S3/Wasabi. +# +# Requires: +# MANIFEST: name of the manifest file +# ARTIFACT_SUFFIX: suffix of the archive to be uploaded (including extension) +# S3_ACCESS_KEY and S3_SECRET_KEY + + +# -E: inherit ERR trap by shell functions +# -e: stop script on ERR trap +# -u: stop script on unbound variables +# -x: print command before running it +# -o pipefail: fail if any command in a pipeline fails +set -Eeuxo pipefail + +aws configure set aws_access_key_id ${S3_ACCESS_KEY} +aws configure set aws_secret_access_key ${S3_SECRET_KEY} +aws configure set default.region us-east-1 + +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="Attorney_Online_${VERSION}_${ARTIFACT_SUFFIX}" + +${S3_COPY} ${S3_MANIFESTS}/${MANIFEST} . +node $(dirname $0)/update_manifest.js ${MANIFEST} ${VERSION} \ + -f ${ARCHIVE} -e Attorney_Online.exe +${S3_COPY} ${ARCHIVE} ${S3_ARCHIVES} +${S3_COPY} ${MANIFEST} ${S3_MANIFESTS} + +rm -f ${MANIFEST} diff --git a/scripts/windows/Dockerfile b/scripts/windows/Dockerfile new file mode 100644 index 00000000..90d6c27e --- /dev/null +++ b/scripts/windows/Dockerfile @@ -0,0 +1,17 @@ +FROM oldmud0/mxe-qt:5.12.1-win32-static-posix +#FROM fffaraz/qt:windows + +ENV TARGET_SPEC i686-w64-mingw32.static.posix + +# Build Discord RPC statically +RUN git clone https://github.com/discordapp/discord-rpc +WORKDIR discord-rpc/build +RUN /opt/mxe/usr/bin/${TARGET_SPEC}-cmake .. -DCMAKE_INSTALL_PREFIX=/opt/mxe/usr/${TARGET_SPEC} +RUN /opt/mxe/usr/bin/${TARGET_SPEC}-cmake --build . --config Release --target install +WORKDIR ../.. + +# Build QtApng statically +RUN git clone https://github.com/Skycoder42/QtApng +WORKDIR QtApng +RUN /opt/mxe/usr/${TARGET_SPEC}/qt5/bin/qmake && make qmake_all && make && make install +WORKDIR .. diff --git a/scripts/windows/Dockerfile-mxe b/scripts/windows/Dockerfile-mxe new file mode 100644 index 00000000..e6caec57 --- /dev/null +++ b/scripts/windows/Dockerfile-mxe @@ -0,0 +1,44 @@ +FROM ubuntu:18.04 + +RUN apt-get update +RUN apt-get install -y \ + autoconf \ + automake \ + autopoint \ + bash \ + bison \ + bzip2 \ + flex \ + g++ \ + g++-multilib \ + gettext \ + git \ + gperf \ + intltool \ + libc6-dev-i386 \ + libgdk-pixbuf2.0-dev \ + libltdl-dev \ + libssl-dev \ + libtool-bin \ + libxml-parser-perl \ + lzip \ + make \ + openssl \ + p7zip-full \ + patch \ + perl \ + pkg-config \ + python \ + ruby \ + sed \ + unzip \ + wget \ + xz-utils + +RUN git clone https://github.com/mxe/mxe.git +RUN mv mxe /opt/mxe +WORKDIR /opt/mxe +RUN make -j4 MXE_TARGETS="i686-w64-mingw32.static.posix" qtbase qtmultimedia +ENV PATH=/opt/mxe/usr/bin:$PATH + +WORKDIR / diff --git a/scripts/windows/how-to-push.md b/scripts/windows/how-to-push.md new file mode 100644 index 00000000..8c1c18d6 --- /dev/null +++ b/scripts/windows/how-to-push.md @@ -0,0 +1,19 @@ +When you want to build a new version of Qt: +```docker +docker build -t mxe-windows-static . -f Dockerfile-mxe +docker tag mxe-windows-static oldmud0/mxe-qt:5.12.1-win32-static-posix +docker push oldmud0/mxe-qt:5.12.1-win32-static-posix +``` + +Remember to log into Docker Hub before attempting to push. + +When you want to build a new version of any dependency required for building AO: +```docker +docker build -t mxe-windows-static-ao . -f Dockerfile +docker tag mxe-windows-static-ao registry.gitlab.com/attorneyonline/ao2-client/builder-windows-i686 +docker push registry.gitlab.com/attorneyonline/ao2-client/builder-windows-i686 +``` + +Remember to create an access token in GitLab before attempting to push. + +GitLab CI depends on `builder-windows-i686` image to be present in the repository's registry in order for the Windows build to succeed. -- cgit From edb3c6b538e80c08595baf71d32356bf0cf97795 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 15:28:30 -0500 Subject: Continue work on manifest scripts --- scripts/.gitignore | 6 ++++ scripts/update_manifest.js | 5 ++-- scripts/wasabi.sh | 72 ++++++++++++++++++++++++++++++++++++++++++++++ scripts/wasabi_asset.sh | 45 ----------------------------- 4 files changed, 81 insertions(+), 47 deletions(-) create mode 100644 scripts/.gitignore create mode 100755 scripts/wasabi.sh delete mode 100755 scripts/wasabi_asset.sh (limited to 'scripts') diff --git a/scripts/.gitignore b/scripts/.gitignore new file mode 100644 index 00000000..2f8a2b91 --- /dev/null +++ b/scripts/.gitignore @@ -0,0 +1,6 @@ +node_modules/ + +# Cursed file +package-lock.json + +s3_keys.sh diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js index 5f64cfb4..66df75f0 100755 --- a/scripts/update_manifest.js +++ b/scripts/update_manifest.js @@ -2,6 +2,7 @@ const fs = require("fs"); const crypto = require("crypto"); +const path = require("path"); const ArgumentParser = require("argparse").ArgumentParser; function isFile(file) { @@ -63,7 +64,7 @@ manifest.versions = [{ full: fullZipFile ? [ { action: "dl", - url: urlBase + encodeURIComponent(fullZipFile), + url: urlBase + encodeURIComponent(path.basename(fullZipFile)), hash: crypto.createHash("sha1") .update(fs.readFileSync(fullZipFile)) .digest("hex") @@ -73,7 +74,7 @@ manifest.versions = [{ ...deleteActions, { action: "dl", - url: urlBase + encodeURIComponent(incrementalZipFile), + url: urlBase + encodeURIComponent(path.basename(incrementalZipFile)), hash: crypto.createHash("sha1") .update(fs.readFileSync(incrementalZipFile)) .digest("hex") diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh new file mode 100755 index 00000000..52006526 --- /dev/null +++ b/scripts/wasabi.sh @@ -0,0 +1,72 @@ +#!/bin/bash +# Updates the specified program manifest to a new archive and version +# and uploads the new archive and manifest to S3/Wasabi. +# +# Requires: +# MANIFEST: name of the manifest file +# S3_ACCESS_KEY, S3_SECRET_KEY: S3 credentials +# ARCHIVE_FULL: name of the full archive (if desired) +# ARCHIVE_INCR: name of the incremental archive (if desired) +# VERSION: name of the new version + + +# -E: inherit ERR trap by shell functions +# -e: stop script on ERR trap +# -u: stop script on unbound variables +# -x: print command before running it +# -o pipefail: fail if any command in a pipeline fails +set -Eeuxo pipefail + +aws configure set aws_access_key_id ${S3_ACCESS_KEY} +aws configure set aws_secret_access_key ${S3_SECRET_KEY} +aws configure set default.region us-east-1 + +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 LAST_TAGGED_VERSION=$(git rev-list --tags --skip=1 --max-count=1) +echo "Previous tagged version: ${LAST_TAGGED_VERSION}" +echo "Current tagged version: ${VERSION}" + +if [[ -n $ARCHIVE_INCR && -n $LAST_TAGGED_VERSION ]]; then + echo "Incremental archive: ${ARCHIVE_INCR}" + + # Get deleted files + export DELETIONS_FILE="deletions.txt" + git log --diff-filter=D --summary ${LAST_TAGGED_VERSION}..HEAD | \ + grep "delete mode" | cut -d' ' -f 5- > ${DELETIONS_FILE} + + # Get added/modified files + git log --name-only --oneline --diff-filter=d ec5c..HEAD | \ + grep -v -E "^[0-9a-f]{7} " | sort -u | zip ${ARCHIVE_INCR} -@ + + export ARCHIVE_INCR_ARG="-i ${ARCHIVE_INCR} ${DELETIONS_FILE}" +elif [[ -n $ARCHIVE_INCR && -z $LAST_TAGGED_VERSION ]]; then + echo "Incremental archive was requested, but there is no previous version" +fi + +if [[ -n $ARCHIVE_FULL ]]; then + echo "Full archive: ${ARCHIVE_INCR}" + export ARCHIVE_FULL_ARG="-f ${ARCHIVE_FULL}" +fi + +${S3_COPY} ${S3_MANIFESTS}/${MANIFEST} . +node $(dirname $0)/update_manifest.js ${MANIFEST} ${VERSION} \ + ${ARCHIVE_FULL_ARG} ${ARCHIVE_INCR_ARG} + +if [[ -n $ARCHIVE_INCR_ARG ]]; then + ${S3_COPY} ${ARCHIVE_INCR} ${S3_ARCHIVES} +fi + +if [[ -n $ARCHIVE_FULL_ARG ]]; then + ${S3_COPY} ${ARCHIVE_FULL} ${S3_ARCHIVES} +fi + +${S3_COPY} ${MANIFEST} ${S3_MANIFESTS} diff --git a/scripts/wasabi_asset.sh b/scripts/wasabi_asset.sh deleted file mode 100755 index d424183a..00000000 --- a/scripts/wasabi_asset.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/bin/bash -# Updates the specified program manifest to a new archive and version -# and uploads the new archive and manifest to S3/Wasabi. -# -# Requires: -# MANIFEST: name of the manifest file -# ARTIFACT_SUFFIX: suffix of the archive to be uploaded (including extension) -# S3_ACCESS_KEY and S3_SECRET_KEY - - -# -E: inherit ERR trap by shell functions -# -e: stop script on ERR trap -# -u: stop script on unbound variables -# -x: print command before running it -# -o pipefail: fail if any command in a pipeline fails -set -Eeuxo pipefail - -aws configure set aws_access_key_id ${S3_ACCESS_KEY} -aws configure set aws_secret_access_key ${S3_SECRET_KEY} -aws configure set default.region us-east-1 - -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_INCR="vanilla_update_${VERSION}_${ARTIFACT_SUFFIX}" - -git log --diff-filter=D --summary $(git rev-list --tags --skip=1 --max-count=1)..HEAD | \ - grep "delete mode" | cut -d' ' -f 5- > deletions.txt - -${S3_COPY} ${S3_MANIFESTS}/${MANIFEST} . -if [[ -n FULL_ZIP && FULL_ZIP != '0' ]]; then - node $(dirname $0)/update_manifest.js ${MANIFEST} ${VERSION} - -f ${ARCHIVE_FULL} -i ${ARCHIVE_INCR} deletions.txt - ${S3_COPY} ${ARCHIVE_FULL} ${S3_ARCHIVES} -else - node $(dirname $0)/update_manifest.js ${MANIFEST} ${VERSION} - -i ${ARCHIVE_INCR} deletions.txt -fi -${S3_COPY} ${ARCHIVE_INCR} ${S3_ARCHIVES} -${S3_COPY} ${MANIFEST} ${S3_MANIFESTS} - -rm -f ${MANIFEST} -- cgit From 4561f1809feb16dff449daa972466e3ed2dfe494 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 16:12:31 -0500 Subject: Fix some bugs in manifest script --- scripts/update_manifest.js | 5 +++-- scripts/wasabi.sh | 11 +++++++---- 2 files changed, 10 insertions(+), 6 deletions(-) (limited to 'scripts') 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} -- cgit From 458eea04d31f749c0494cf78d040bf8e80ddf9da Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 16:18:05 -0500 Subject: Fix unbound variable EXECUTABLE --- scripts/wasabi.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh index 2e8932d9..0613ffdd 100755 --- a/scripts/wasabi.sh +++ b/scripts/wasabi.sh @@ -56,13 +56,13 @@ if [[ -n $ARCHIVE_FULL ]]; then export ARCHIVE_FULL_ARG="-f ${ARCHIVE_FULL}" fi -if [[ -n $EXECUTABLE ]]; then +if [[ -v $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} ${EXECUTABLE} + ${ARCHIVE_FULL_ARG} ${ARCHIVE_INCR_ARG} ${EXECUTABLE_ARG} if [[ -n $ARCHIVE_INCR_ARG ]]; then ${S3_COPY} ${ARCHIVE_INCR} ${S3_ARCHIVES} -- cgit From d75cee4996af64336c7823968c8cdb475b5c5aff Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 16:21:51 -0500 Subject: Fix unbound variable (again) --- scripts/wasabi.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh index 0613ffdd..a322b6c0 100755 --- a/scripts/wasabi.sh +++ b/scripts/wasabi.sh @@ -56,7 +56,7 @@ if [[ -n $ARCHIVE_FULL ]]; then export ARCHIVE_FULL_ARG="-f ${ARCHIVE_FULL}" fi -if [[ -v $EXECUTABLE ]]; then +if [[ -v EXECUTABLE ]]; then export EXECUTABLE_ARG="-e ${EXECUTABLE}" fi -- cgit From 153c458f9e6d95a3e1ee205be28dbdbb32ee88eb Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 16:32:10 -0500 Subject: Fix type errors during argument parsing --- scripts/update_manifest.js | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'scripts') diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js index ea1f85e6..bcb3ac7b 100755 --- a/scripts/update_manifest.js +++ b/scripts/update_manifest.js @@ -40,11 +40,14 @@ argParser.addArgument([ "-e", "--executable" ], { const { manifestFile, version, - fullZipFile, - incremental, - executable + fullZipFileArgs, + incrementalArgs, + executableArgs } = argParser.parseArgs(); -const [incrementalZipFile, deletionsFile] = incremental || []; + +const [incrementalZipFile, deletionsFile] = incrementalArgs || []; +const [fullZipFile] = fullZipFileArgs || []; +const [executable] = executableArgs || []; const manifest = JSON.parse(fs.readFileSync(manifestFile)); @@ -71,7 +74,7 @@ manifest.versions = [{ .digest("hex") } ] : undefined, - update: incremental ? [ + update: incrementalArgs ? [ ...deleteActions, { action: "dl", -- cgit From bc92942d29eb43b6f8a37ca8ae4ca303a5f28b96 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 16:47:16 -0500 Subject: Allow overwriting versions of same name --- scripts/update_manifest.js | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) (limited to 'scripts') diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js index bcb3ac7b..71fa3f86 100755 --- a/scripts/update_manifest.js +++ b/scripts/update_manifest.js @@ -26,15 +26,15 @@ argParser.addArgument("version", { }); argParser.addArgument([ "-f", "--full" ], { metavar: "", type: isFile, nargs: 1, - dest: "fullZipFile" + dest: "fullZipFileArgs" }); argParser.addArgument([ "-i", "--incremental" ], { - type: isFile, nargs: 2, dest: "incremental", + type: isFile, nargs: 2, dest: "incrementalArgs", metavar: ["", ""] }); argParser.addArgument([ "-e", "--executable" ], { metavar: "[executable file]", nargs: 1, - dest: "executable" + dest: "executableArgs" }); const { @@ -49,6 +49,12 @@ const [incrementalZipFile, deletionsFile] = incrementalArgs || []; const [fullZipFile] = fullZipFileArgs || []; const [executable] = executableArgs || []; +// Do one final check +if (!incrementalZipFile && !fullZipFile) { + console.error("No download archive specified! Abort."); + process.exit(1); +} + const manifest = JSON.parse(fs.readFileSync(manifestFile)); const deleteActions = deletionsFile ? fs.readFileSync(deletionsFile) @@ -61,7 +67,7 @@ const deleteActions = deletionsFile ? fs.readFileSync(deletionsFile) const urlBase = "https://s3.wasabisys.com/ao-downloads/"; -manifest.versions = [{ +const versionEntry = { version, executable, prev: manifest.versions[0] ? manifest.versions[0].version : undefined, @@ -84,6 +90,18 @@ manifest.versions = [{ .digest("hex") } ] : undefined -}, ...manifest.versions]; +}; + +const existingVersion = manifest.versions.filter(v => v.version == version); +if (existingVersion) { + console.warn(`Warning: version ${version} already exists. Adding new values.`); + + // Don't overwrite prev - it will cause headaches + delete versionEntry.prev; + + Object.assign(existingVersion, versionEntry); +} else { + manifest.versions = [versionEntry, ...manifest.versions]; +} fs.writeFileSync(manifestFile, JSON.stringify(manifest, null, 4)); -- cgit From a5435183e4a181c75624442866014c132238c7d8 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 17:04:39 -0500 Subject: Stronger check for array length --- scripts/update_manifest.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'scripts') diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js index 71fa3f86..adbdc349 100755 --- a/scripts/update_manifest.js +++ b/scripts/update_manifest.js @@ -92,14 +92,17 @@ const versionEntry = { ] : undefined }; -const existingVersion = manifest.versions.filter(v => v.version == version); -if (existingVersion) { +console.log("Generated version entry:", versionEntry); + +const existingVersions = manifest.versions.filter(v => v.version == version); +if (existingVersions.length > 0) { console.warn(`Warning: version ${version} already exists. Adding new values.`); // Don't overwrite prev - it will cause headaches delete versionEntry.prev; - Object.assign(existingVersion, versionEntry); + Object.assign(existingVersions[0], versionEntry); + console.log("Merged version entry:", existingVersions[0]); } else { manifest.versions = [versionEntry, ...manifest.versions]; } -- cgit From 190b0d7c1e5e5461958ff7ec0576da7671a161c9 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 17:10:24 -0500 Subject: Fix issues parsing deletions file --- scripts/update_manifest.js | 2 ++ 1 file changed, 2 insertions(+) (limited to 'scripts') diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js index adbdc349..220439c5 100755 --- a/scripts/update_manifest.js +++ b/scripts/update_manifest.js @@ -58,6 +58,8 @@ if (!incrementalZipFile && !fullZipFile) { const manifest = JSON.parse(fs.readFileSync(manifestFile)); const deleteActions = deletionsFile ? fs.readFileSync(deletionsFile) + .toString() + .trim() .split("\n").map(file => { // XXX: This does not delete empty directories. Finding them would // actually be a substantial amount of work because Git does not -- cgit From ed41f3c4e5964600063bbab2bf27265ede9e4c19 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 17:14:44 -0500 Subject: Remove S3_MANIFESTS and S3_ARCHIVES --- scripts/wasabi.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh index a322b6c0..12b310e4 100755 --- a/scripts/wasabi.sh +++ b/scripts/wasabi.sh @@ -5,6 +5,7 @@ # Requires: # MANIFEST: name of the manifest file # S3_ACCESS_KEY, S3_SECRET_KEY: S3 credentials +# S3_MANIFESTS, S3_ARCHIVES: S3 paths to manifests and downloads # ARCHIVE_FULL: name of the full archive (if desired) # ARCHIVE_INCR: name of the incremental archive (if desired) # VERSION: name of the new version @@ -23,8 +24,6 @@ aws configure set aws_secret_access_key ${S3_SECRET_KEY} aws configure set default.region us-east-1 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 ARCHIVE_FULL_ARG="" export ARCHIVE_INCR_ARG="" -- cgit From f4b31356df011decba4e157a6d8d2c24f17ade2e Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 17:22:05 -0500 Subject: Fix typo in getting added/modified files --- scripts/wasabi.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh index 12b310e4..2067e5ed 100755 --- a/scripts/wasabi.sh +++ b/scripts/wasabi.sh @@ -42,7 +42,7 @@ if [[ -n $ARCHIVE_INCR && -n $LAST_TAGGED_VERSION ]]; then grep "delete mode" | cut -d' ' -f 5- > ${DELETIONS_FILE} # Get added/modified files - git log --name-only --oneline --diff-filter=d ec5c..HEAD | \ + git log --name-only --oneline --diff-filter=d ${LAST_TAGGED_VERSION}..HEAD | \ grep -v -E "^[0-9a-f]{7} " | sort -u | zip ${ARCHIVE_INCR} -@ export ARCHIVE_INCR_ARG="-i ${ARCHIVE_INCR} ${DELETIONS_FILE}" -- cgit From 9b4c18e8dc151ca0387e8d4514b8d9886d03caa7 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 22:58:05 -0500 Subject: Cover rename and deleted directory cases --- scripts/update_manifest.js | 59 ++++++++++++++++++++++++++++++++++++++-------- scripts/wasabi.sh | 13 +++++----- 2 files changed, 55 insertions(+), 17 deletions(-) (limited to 'scripts') diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js index 220439c5..19e1b152 100755 --- a/scripts/update_manifest.js +++ b/scripts/update_manifest.js @@ -30,7 +30,7 @@ argParser.addArgument([ "-f", "--full" ], { }); argParser.addArgument([ "-i", "--incremental" ], { type: isFile, nargs: 2, dest: "incrementalArgs", - metavar: ["", ""] + metavar: ["", ""] }); argParser.addArgument([ "-e", "--executable" ], { metavar: "[executable file]", nargs: 1, @@ -45,7 +45,7 @@ const { executableArgs } = argParser.parseArgs(); -const [incrementalZipFile, deletionsFile] = incrementalArgs || []; +const [incrementalZipFile, changesFile] = incrementalArgs || []; const [fullZipFile] = fullZipFileArgs || []; const [executable] = executableArgs || []; @@ -55,17 +55,56 @@ if (!incrementalZipFile && !fullZipFile) { process.exit(1); } +// Do a quick litmus test to prevent deleting everything incorrectly +if (changesFile && !fs.existsSync("base")) { + console.error("The working directory must be set to an " + + "asset folder in order for deleted directories " + + "to be calculated correctly. Abort."); + process.exit(1); +} + const manifest = JSON.parse(fs.readFileSync(manifestFile)); -const deleteActions = deletionsFile ? fs.readFileSync(deletionsFile) +const dirsDeleted = new Set(); +const specialActions = changesFile ? + fs.readFileSync(changesFile) .toString() .trim() - .split("\n").map(file => { - // XXX: This does not delete empty directories. Finding them would - // actually be a substantial amount of work because Git does not - // give us a good way of finding directories that were deleted. - return { action: "delete", target: file }; - }) : []; + .split("\n") + .map(line => line.split("\t")) + .map(([mode, target, source]) => { + switch (mode[0]) { + case "D": // Deleted + // Check if the folder exists relative to the working + // directory, and if not, add it to the dirsDeleted list. + // Keep going up the tree to see how many directories were + // deleted. + let dir = path.dirname(target); + while (!dirsDeleted.has(dir) && !fs.existsSync(dir)) { + dirsDeleted.add(dir); + dir = path.dirname(dir); + } + + return { action: "delete", target }; + case "R": // Renamed + // NOTE: Make sure that the launcher's implementation of + // the move action also creates directories when needed. + return { action: "move", source, target}; + default: + return null; + } + }) + // Remove ignored file mode changes + .filter(action => action !== null) + // Create actions based on directories to be deleted. + // Always have deeper directories first, to guarantee that deleting + // higher-level directories will succeed. + + Array.from(dirsDeleted.values()) + .sort((a, b) => b.split("/").length - a.split("/").length) + .map(dir => { + return { action: "deleteDir", target: dir }; + }) + : []; const urlBase = "https://s3.wasabisys.com/ao-downloads/"; @@ -83,7 +122,7 @@ const versionEntry = { } ] : undefined, update: incrementalArgs ? [ - ...deleteActions, + ...specialActions, { action: "dl", url: urlBase + encodeURIComponent(path.basename(incrementalZipFile)), diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh index 2067e5ed..a20c0e06 100755 --- a/scripts/wasabi.sh +++ b/scripts/wasabi.sh @@ -36,16 +36,15 @@ echo "Current tagged version: ${VERSION}" if [[ -n $ARCHIVE_INCR && -n $LAST_TAGGED_VERSION ]]; then echo "Incremental archive: ${ARCHIVE_INCR}" - # Get deleted files - export DELETIONS_FILE="deletions.txt" - git log --diff-filter=D --summary ${LAST_TAGGED_VERSION}..HEAD | \ - grep "delete mode" | cut -d' ' -f 5- > ${DELETIONS_FILE} + # Get all files + export CHANGES_FILE="changes.txt" + git diff --summary ${LAST_TAGGED_VERSION}..HEAD > ${CHANGES_FILE} # Get added/modified files - git log --name-only --oneline --diff-filter=d ${LAST_TAGGED_VERSION}..HEAD | \ - grep -v -E "^[0-9a-f]{7} " | sort -u | zip ${ARCHIVE_INCR} -@ + git diff --name-only --diff-filter=dr ${LAST_TAGGED_VERSION}..HEAD | \ + zip ${ARCHIVE_INCR} -@ - export ARCHIVE_INCR_ARG="-i ${ARCHIVE_INCR} ${DELETIONS_FILE}" + export ARCHIVE_INCR_ARG="-i ${ARCHIVE_INCR} ${CHANGES_FILE}" elif [[ -n $ARCHIVE_INCR && -z $LAST_TAGGED_VERSION ]]; then echo "Incremental archive was requested, but there is no previous version" fi -- cgit From eae8ed1552085fccbd87049fe438b2f6284b3b95 Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 23:18:28 -0500 Subject: I hate JavaScript sometimes --- scripts/update_manifest.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/update_manifest.js b/scripts/update_manifest.js index 19e1b152..1a06a2d7 100755 --- a/scripts/update_manifest.js +++ b/scripts/update_manifest.js @@ -99,11 +99,11 @@ const specialActions = changesFile ? // Create actions based on directories to be deleted. // Always have deeper directories first, to guarantee that deleting // higher-level directories will succeed. - + Array.from(dirsDeleted.values()) + .concat(Array.from(dirsDeleted.values()) .sort((a, b) => b.split("/").length - a.split("/").length) .map(dir => { return { action: "deleteDir", target: dir }; - }) + })) : []; const urlBase = "https://s3.wasabisys.com/ao-downloads/"; -- cgit From 93b482cbc794c343d9f61a8c37bf900dfd925d1c Mon Sep 17 00:00:00 2001 From: oldmud0 Date: Wed, 3 Apr 2019 23:24:37 -0500 Subject: Use --name-status instead of --summary --- scripts/wasabi.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'scripts') diff --git a/scripts/wasabi.sh b/scripts/wasabi.sh index a20c0e06..95fb3ee9 100755 --- a/scripts/wasabi.sh +++ b/scripts/wasabi.sh @@ -38,7 +38,7 @@ if [[ -n $ARCHIVE_INCR && -n $LAST_TAGGED_VERSION ]]; then # Get all files export CHANGES_FILE="changes.txt" - git diff --summary ${LAST_TAGGED_VERSION}..HEAD > ${CHANGES_FILE} + git diff --name-status ${LAST_TAGGED_VERSION}..HEAD > ${CHANGES_FILE} # Get added/modified files git diff --name-only --diff-filter=dr ${LAST_TAGGED_VERSION}..HEAD | \ -- cgit