]> de.git.xonotic.org Git - xonotic/xonotic.git/commitdiff
Change update-to-release.sh to be a symlink to update-to-autobuild.sh
authorbones_was_here <bones_was_here@xa.org.au>
Tue, 2 Aug 2022 19:13:36 +0000 (05:13 +1000)
committerbones_was_here <bones_was_here@xa.org.au>
Tue, 2 Aug 2022 19:23:27 +0000 (05:23 +1000)
The scripts are identical and check their own filenames to decide which
build to rsync to, so it appears this was the intended configuration,
similar to the xonotic-linux-*.sh scripts.

misc/tools/rsync-updater/update-to-release.sh [changed from file to symlink]

deleted file mode 100755 (executable)
index 32ce1f2a5e21d857445bd2da18cc80dc3d06f6bd..0000000000000000000000000000000000000000
+++ /dev/null
@@ -1,93 +0,0 @@
-#!/bin/sh
-
-if [ -d "${0%/*}" ]; then
-       cd "${0%/*}"
-fi
-
-if ! which rsync >/dev/null; then
-       echo >&2 "FATAL: rsync not found, please install the rsync package"
-       exit 1
-fi
-
-[ "$1" = "-y" ] && choice=y
-until [ "$choice" = y ] || [ "$choice" = Y ]; do
-       read -rp "This script will DELETE any custom files in the Xonotic folder. Do you want to continue [Y/N]? " choice
-       [ "$choice" = n ] || [ "$choice" = N ] && exit 1
-done
-
-case "${0##*/}" in
-       update-to-autobuild.sh)
-               buildtype=autobuild
-               ;;
-       *)
-               buildtype=release
-               ;;
-esac
-
-options="-Prtzil --executability --delete-after --delete-excluded --stats"
-
-if [ -d "Xonotic-low" ]; then
-       echo NOTE: Xonotic-low is gone, downloading normal Xonotic.
-       url="rsync://beta.xonotic.org/$buildtype-Xonotic/"
-       target="Xonotic-low/"
-elif [ -d "Xonotic-high" ]; then
-       url="rsync://beta.xonotic.org/$buildtype-Xonotic-high/"
-       target="Xonotic-high/"
-elif [ -d "../../../.git" ]; then
-       echo >&2 "NOTE: this is a git repository download. Using the regular update method."
-       exec ../../../all update
-elif [ -d "../../../data" ]; then
-       if [ -f ../../../data/xonotic-rsync-data-low.pk3 ]; then
-               echo NOTE: Xonotic-low is gone, downloading normal Xonotic.
-               url="rsync://beta.xonotic.org/$buildtype-Xonotic/"
-       elif [ -f ../../../data/xonotic-*-data-low.pk3 ]; then
-               echo NOTE: Xonotic-low is gone, downloading normal Xonotic.
-               url="rsync://beta.xonotic.org/$buildtype-Xonotic/"
-               options="$options -y" # use fuzzy matching because file names differ
-       elif [ -f ../../../data/xonotic-rsync-data-high.pk3 ]; then
-               url="rsync://beta.xonotic.org/$buildtype-Xonotic-high/"
-       elif [ -f ../../../data/xonotic-*-data-high.pk3 ]; then
-               url="rsync://beta.xonotic.org/$buildtype-Xonotic-high/"
-               options="$options -y" # use fuzzy matching because file names differ
-       elif [ -f ../../../data/xonotic-rsync-data.pk3 ]; then
-               url="rsync://beta.xonotic.org/$buildtype-Xonotic/"
-       elif [ -f ../../../data/xonotic-*-data.pk3 ]; then
-               url="rsync://beta.xonotic.org/$buildtype-Xonotic/"
-               options="$options -y" # use fuzzy matching because file names differ
-       else
-               echo >&2 "FATAL: unrecognized Xonotic build. This update script cannot be used."
-               exit 1
-       fi
-       target="../../.."
-else
-       url="rsync://beta.xonotic.org/$buildtype-Xonotic/"
-       target="Xonotic/"
-fi
-
-excludes=
-if [ -z "$XONOTIC_INCLUDE_ALL" ]; then
-       excludes="$excludes --exclude=/*.exe"
-       excludes="$excludes --exclude=/gmqcc/*.exe"
-       excludes="$excludes --exclude=/bin32"
-       excludes="$excludes --exclude=/*.dll"
-       excludes="$excludes --exclude=/bin64"
-
-       case `uname`:`uname -m` in
-               Darwin:*)
-                       excludes="$excludes --exclude=/xonotic-linux*"
-                       excludes="$excludes --exclude=/gmqcc/gmqcc.linux*"
-                       ;;
-               Linux:x86_64)
-                       excludes="$excludes --exclude=/Xonotic*.app"
-                       excludes="$excludes --exclude=/xonotic-osx-*"
-                       excludes="$excludes --exclude=/gmqcc/gmqcc.osx"
-                       excludes="$excludes --exclude=/xonotic-linux32-*"
-                       excludes="$excludes --exclude=/gmqcc/gmqcc.linux32"
-                       ;;
-               *)
-                       echo >&2 "WARNING: Could not detect architecture - downloading all architectures"
-                       ;;
-       esac
-fi
-
-rsync $options $excludes "$url" "$target"
new file mode 120000 (symlink)
index 0000000000000000000000000000000000000000..4d9d6f291aa52d96ce6efeea4af9fd1ff175dd54
--- /dev/null
@@ -0,0 +1 @@
+update-to-autobuild.sh
\ No newline at end of file