Transferring your save failed! Continuing with former version.
"}
EOF
- cecho ": failed!"
- cecho
- cecho "Transferring your save failed! Continuing with former version."
+ cecho ": failed!"
+ cecho
+ cecho "Transferring your save failed! Continuing with former version."
cecho -n "--- any key to continue ---"
- read -n 1 -s
- cecho
- fi
+ read -n 1 -s
+ cecho
+ fi
else
wcat <Transferring failed!
@@ -188,12 +188,12 @@ EOF
"}
EOF
- cecho ": failed!"
- cecho
- cecho "Target version is corrupt! Continuing with former version."
+ cecho ": failed!"
+ cecho
+ cecho "Target version is corrupt! Continuing with former version."
cecho -n "--- any key to continue ---"
- read -n 1 -s
- cecho
+ read -n 1 -s
+ cecho
fi
wecho '{"msg":"hide_dialog"}'
}
@@ -217,10 +217,10 @@ if [[ -n "$SAVE" ]]; then
then
current_ver="$(hash-description $OUR_GAME_HASH)"
cecho "Hi, you have a $current_ver save game:"
- cecho
+ cecho
- OUR_SGV_MAJOR="$(major-version-for-game $OUR_GAME_HASH)"
- NEW_GAME_HASH="$(newest-version-with-major-version $OUR_SGV_MAJOR)"
+ OUR_SGV_MAJOR="$(major-version-for-game $OUR_GAME_HASH)"
+ NEW_GAME_HASH="$(newest-version-with-major-version $OUR_SGV_MAJOR)"
new_ver="$(hash-description $NEW_GAME_HASH)"
if [[ "$OUR_GAME_HASH" != "$NEW_GAME_HASH" &&
@@ -228,8 +228,8 @@ if [[ -n "$SAVE" ]]; then
wecho '{"msg":"layer", "layer":"crt"}'
wecho -n '{"msg":"show_dialog", "html":"'
- if [[ "${NEW_GAME_HASH}" != "${LATEST_GAME_HASH}" ]]; then
- cecho "There's a newer version ($new_ver) that can load your save."
+ if [[ "${NEW_GAME_HASH}" != "${LATEST_GAME_HASH}" ]]; then
+ cecho "There's a newer version ($new_ver) that can load your save."
cecho -n "[T]ransfer your save to this version?"
wcat <There's a newer version ($new_ver) that can load your save.
@@ -239,8 +239,8 @@ if [[ -n "$SAVE" ]]; then
"}
EOF
read -n 1 -s REPLY
- cecho
- else
+ cecho
+ else
cecho -n "[T]ransfer your save to the latest version ($new_ver)?"
wcat <[T]ransfer your save to the latest version ($new_ver)?
@@ -248,30 +248,30 @@ EOF
"}
EOF
- read -n 1 -s REPLY
- cecho
- fi
+ read -n 1 -s REPLY
+ cecho
+ fi
wecho '{"msg":"hide_dialog"}'
- if test "$REPLY" = "t" -o "$REPLY" = "T" -o "$REPLY" = "y" -o "$REPLY" = "Y"
- then
- cecho -n "Transferring..."
+ if test "$REPLY" = "t" -o "$REPLY" = "T" -o "$REPLY" = "y" -o "$REPLY" = "Y"
+ then
+ cecho -n "Transferring..."
transfer-save "$SAVE" "$NEW_GAME_HASH"
- fi
- else
- if test "${TRANSFER_ENABLED}" != "1"
- then
- cecho "Transfering of saves is currently disabled."
- cecho "Finish your game or end your character to play in latest version."
- else
- cecho "Your save cannot be tranferred though because of incompatibility."
- cecho "Finish your game or end your character to play in latest version."
- fi
+ fi
+ else
+ if test "${TRANSFER_ENABLED}" != "1"
+ then
+ cecho "Transfering of saves is currently disabled."
+ cecho "Finish your game or end your character to play in latest version."
+ else
+ cecho "Your save cannot be tranferred though because of incompatibility."
+ cecho "Finish your game or end your character to play in latest version."
+ fi
cecho -n "--- any key to continue ---"
- [[ -z "$WEBTILES" ]] && read -n 1 -t 5 -s
- cecho
- fi
+ [[ -z "$WEBTILES" ]] && read -n 1 -t 5 -s
+ cecho
+ fi
fi
else
OUR_GAME_HASH="${LATEST_GAME_HASH}"
diff --git a/chroot/bin/crawl-stable-launcher.sh b/chroot/bin/crawl-stable-launcher.sh
index cca5ba42..c9f9525f 100755
--- a/chroot/bin/crawl-stable-launcher.sh
+++ b/chroot/bin/crawl-stable-launcher.sh
@@ -14,11 +14,11 @@
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
-# along with this program. If not, see .
+# along with this program. If not, see .
# ===========================================================================
#
diff --git a/chroot/bin/init-webtiles.sh b/chroot/bin/init-webtiles.sh
index 6b75424c..c1fae622 100755
--- a/chroot/bin/init-webtiles.sh
+++ b/chroot/bin/init-webtiles.sh
@@ -5,8 +5,8 @@ NAME=$1
VERSIONS="git $(seq 25 25 | sed 's/^/0./')"
for v in $VERSIONS; do
- cp --no-clobber "%%CHROOT_DGLDIR%%/data/crawl-$v-settings/init.txt" "%%CHROOT_RCFILESDIR%%/crawl-$v/$NAME.rc"
- cp --no-clobber "%%CHROOT_DGLDIR%%/data/crawl-git.macro" "%%CHROOT_RCFILESDIR%%/crawl-$v/$NAME.macro"
+ cp --no-clobber "%%CHROOT_DGLDIR%%/data/crawl-$v-settings/init.txt" "%%CHROOT_RCFILESDIR%%/crawl-$v/$NAME.rc"
+ cp --no-clobber "%%CHROOT_DGLDIR%%/data/crawl-git.macro" "%%CHROOT_RCFILESDIR%%/crawl-$v/$NAME.macro"
done
cp --no-clobber "%%CHROOT_DGLDIR%%/data/crawl-dcssca-settings/init.txt" "%%CHROOT_RCFILESDIR%%/crawl-dcssca/$NAME.rc"
diff --git a/chroot/bin/savegame-backup.sh b/chroot/bin/savegame-backup.sh
index 1be82b1d..985d3547 100755
--- a/chroot/bin/savegame-backup.sh
+++ b/chroot/bin/savegame-backup.sh
@@ -11,11 +11,11 @@
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
-# along with this program. If not, see .
+# along with this program. If not, see .
# ===========================================================================
#
@@ -58,7 +58,7 @@ savedir-containing() {
local char="$1"
local -a saves
saves=($PREFIX/$BINARY_SAVE_NAME{,-*}/saves/$char{,-$USER_ID}.{cs,chr,sav})
- local savefile
+ local savefile
savefile="$(first-existing-file "${saves[@]}")"
[[ -n "$savefile" ]] && dirname "$savefile"
return 0
@@ -131,14 +131,13 @@ if [[ -n "$SAVE_FOUND" && -f "$SAVE_FOUND" ]]; then
if test $? -ne 0
then
- echo -e " ${C_RED}failed!${C_NORMAL}"
+ echo -e " ${C_RED}failed!${C_NORMAL}"
else
- echo -e " ${C_GREEN}successful.${C_NORMAL}"
- echo "- ${HTTP_LINK}/$TARNAME"
- echo
- echo "Please provide this link in your bug-report or give it to a developer."
+ echo -e " ${C_GREEN}successful.${C_NORMAL}"
+ echo "- ${HTTP_LINK}/$TARNAME"
+ echo
+ echo "Please provide this link in your bug-report or give it to a developer."
fi
else
echo "Your character ($CHAR_NAME) was not found in $SAVES."
fi
-
diff --git a/chroot/data/menus/crawl-0.25.txt b/chroot/data/menus/crawl-0.25.txt
index 61ae7489..eadea354 100644
--- a/chroot/data/menus/crawl-0.25.txt
+++ b/chroot/data/menus/crawl-0.25.txt
@@ -20,4 +20,4 @@ A)dvanced options
q) Return to main menu
-=>
+=>
\ No newline at end of file
diff --git a/chroot/data/menus/crawl-0.25_adv.txt b/chroot/data/menus/crawl-0.25_adv.txt
index 92f5f446..069e3c7a 100644
--- a/chroot/data/menus/crawl-0.25_adv.txt
+++ b/chroot/data/menus/crawl-0.25_adv.txt
@@ -19,4 +19,4 @@ O) Reset options
q) Return to previous menu
-=>
+=>
\ No newline at end of file
diff --git a/chroot/data/menus/crawl_git.txt b/chroot/data/menus/crawl_git.txt
index ad01cba0..88d01fd8 100644
--- a/chroot/data/menus/crawl_git.txt
+++ b/chroot/data/menus/crawl_git.txt
@@ -20,4 +20,4 @@ A)dvanced options
q) Return to main menu
-=>
+=>
\ No newline at end of file
diff --git a/chroot/data/menus/crawl_git_adv.txt b/chroot/data/menus/crawl_git_adv.txt
index 7dda259c..00a0f21f 100644
--- a/chroot/data/menus/crawl_git_adv.txt
+++ b/chroot/data/menus/crawl_git_adv.txt
@@ -19,4 +19,4 @@ O) Reset options
q) Return to previous menu
-=>
+=>
\ No newline at end of file
diff --git a/chroot/data/menus/experimental.txt b/chroot/data/menus/experimental.txt
index 4c83d43b..a8798c63 100644
--- a/chroot/data/menus/experimental.txt
+++ b/chroot/data/menus/experimental.txt
@@ -15,4 +15,4 @@ without warning: don't get too attached to your character. Thanks for helping
us evaluate potential new features!
q) Return to trunk menu
-=>
+=>
\ No newline at end of file
diff --git a/chroot/data/menus/main_admin.txt b/chroot/data/menus/main_admin.txt
index 881560fb..a2a7372e 100644
--- a/chroot/data/menus/main_admin.txt
+++ b/chroot/data/menus/main_admin.txt
@@ -20,4 +20,4 @@ G) GoonCrawl
H) X-Crawl
-=>
+=>
\ No newline at end of file
diff --git a/chroot/data/menus/main_anon.txt b/chroot/data/menus/main_anon.txt
index bb59a285..b57d935d 100644
--- a/chroot/data/menus/main_anon.txt
+++ b/chroot/data/menus/main_anon.txt
@@ -15,4 +15,4 @@ L) Login
Q) Quit
-=>
+=>
\ No newline at end of file
diff --git a/chroot/data/menus/main_user.txt b/chroot/data/menus/main_user.txt
index 09e638ae..196b6fbc 100644
--- a/chroot/data/menus/main_user.txt
+++ b/chroot/data/menus/main_user.txt
@@ -20,4 +20,4 @@ H) X-Crawl
Z) Change password X) Change email address
-=>
+=>
\ No newline at end of file
diff --git a/chroot/sbin/install-stable.sh b/chroot/sbin/install-stable.sh
index d0d327a9..bbfc592f 100755
--- a/chroot/sbin/install-stable.sh
+++ b/chroot/sbin/install-stable.sh
@@ -15,11 +15,11 @@
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
-# along with this program. If not, see .
+# along with this program. If not, see .
# ===========================================================================
#
@@ -75,29 +75,29 @@ copy-data-files() {
}
create-dgl-directories() {
- mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION-sprint/"
- mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION-tut/"
+ mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION-sprint/"
+ mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION-tut/"
mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION-descent/"
- mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION-zotdef/"
- mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION/"
- mkdir -p "$CHROOT/dgldir/rcfiles/crawl-$VERSION/"
- mkdir -p "$CHROOT/dgldir/data/crawl-$VERSION-settings/"
+ mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION-zotdef/"
+ mkdir -p "$CHROOT/dgldir/inprogress/crawl-$VERSION/"
+ mkdir -p "$CHROOT/dgldir/rcfiles/crawl-$VERSION/"
+ mkdir -p "$CHROOT/dgldir/data/crawl-$VERSION-settings/"
}
fix-chroot-directory-permissions() {
- chown -R crawl:crawl "$CHROOT/crawl-master"
- chown -R crawl:crawl "$CHROOT/dgldir"
+ chown -R crawl:crawl "$CHROOT/crawl-master"
+ chown -R crawl:crawl "$CHROOT/dgldir"
}
install-game() {
mkdir -p $SAVEDIR/{,sprint,descent,zotdef}
mkdir -p $DATADIR
- create-dgl-directories
- fix-chroot-directory-permissions
+ create-dgl-directories
+ fix-chroot-directory-permissions
copy-game-binary
copy-data-files
-
+
chown -R $CRAWL_UGRP $SAVEDIR
}
diff --git a/chroot/sbin/install-trunk.sh b/chroot/sbin/install-trunk.sh
index 91bd923a..e5dfebc6 100755
--- a/chroot/sbin/install-trunk.sh
+++ b/chroot/sbin/install-trunk.sh
@@ -15,11 +15,11 @@
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
-# along with this program. If not, see .
+# along with this program. If not, see .
# ===========================================================================
#
@@ -109,7 +109,7 @@ install-game() {
copy-game-binary
copy-data-files
link-logfiles
-
+
chown -R $CRAWL_UGRP $SAVEDIR
ln -snf $GAME_BINARY $CHROOT$CHROOT_CRAWL_BASEDIR/crawl-latest
}
@@ -178,7 +178,7 @@ if [[ -n "${SGV_MAJOR}" && -n "${SGV_MINOR}" ]]; then
GAME_BINARY=$GAME-$REVISION
BINARIES_DIR=$CHROOT$CHROOT_BINARIES
-
+
WEBDIR=$CHROOT$CHROOT_CRAWL_BASEDIR/webserver
GAMEDIR=$CHROOT$CHROOT_CRAWL_BASEDIR/$GAME_BINARY
# Absolute path to save game directory
diff --git a/chroot/sbin/remove-trunks.sh b/chroot/sbin/remove-trunks.sh
index 024fe1a7..cc1820dd 100755
--- a/chroot/sbin/remove-trunks.sh
+++ b/chroot/sbin/remove-trunks.sh
@@ -11,11 +11,11 @@
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
-# along with this program. If not, see .
+# along with this program. If not, see .
# ===========================================================================
#
@@ -103,47 +103,47 @@ list_hashes()
cd $CHROOT/$BASE_DIR
if verbose; then
- echo "Date Version Amount Players"
- echo "**************************************************************"
+ echo "Date Version Amount Players"
+ echo "**************************************************************"
- for folder in $(savegame-dirs); do
+ for folder in $(savegame-dirs); do
local hash=${folder/$GAME_BASE/}
local version_detail="$(hash-version-detail $hash)"
local save_count="$(count-saves-in-dir "$folder")"
- /bin/ls -1tdl ${folder} 2>/dev/null | \
- sed "s/$GAME_BASE//g;" | \
- awk '{ printf "%3s %2s %s %17s %6s ",
+ /bin/ls -1tdl ${folder} 2>/dev/null | \
+ sed "s/$GAME_BASE//g;" | \
+ awk '{ printf "%3s %2s %s %17s %6s ",
$6, $7, $8,
"'"$version_detail"'",
"'"$save_count"'" }'
- for char in $(saves-in-dir "$folder" | strip-save-uid-extension)
- do
- echo -n "${char#$folder/saves/} "
- done
+ for char in $(saves-in-dir "$folder" | strip-save-uid-extension)
+ do
+ echo -n "${char#$folder/saves/} "
+ done
- echo
- done
+ echo
+ done
else
- echo "Date Version Players in Games"
- echo "*******************************************************************"
+ echo "Date Version Players in Games"
+ echo "*******************************************************************"
- for folder in $(savegame-dirs)
- do
+ for folder in $(savegame-dirs)
+ do
local hash=${folder/$GAME_BASE/}
local version_detail="$(hash-version-detail $hash)"
local save_count="$(count-saves-in-dir "$folder" '')"
local sprint_save_count="$(count-saves-in-dir "$folder" 'sprint')"
local zotdef_save_count="$(count-saves-in-dir "$folder" 'zotdef')"
- /bin/ls -1tdl ${folder} 2>/dev/null | \
- sed "s/$GAME_BASE//g;" | \
- awk '{ printf "%3s %2s %s %17s %6s in trunk, %3s in sprint, %3s in zotdef", $6, $7, $8,
+ /bin/ls -1tdl ${folder} 2>/dev/null | \
+ sed "s/$GAME_BASE//g;" | \
+ awk '{ printf "%3s %2s %s %17s %6s in trunk, %3s in sprint, %3s in zotdef", $6, $7, $8,
"'"$version_detail"'",
"'"$save_count"'",
"'"$sprint_save_count"'",
"'"$zotdef_save_count"'" }'
- echo
- done
+ echo
+ done
fi
}
@@ -152,8 +152,8 @@ PARAMS="$(echo "$*" | sed 's/[$*\/();|+]//g')"
if test $# -eq 0
then
if prompts-enabled; then
- echo "Usage: $(basename $0) [-q] [-v] [hash] [hash] ..."
- echo
+ echo "Usage: $(basename $0) [-q] [-v] [hash] [hash] ..."
+ echo
fi
list_hashes
echo
@@ -179,34 +179,34 @@ do
echo "$GAME_SAVEDIR contains save games, use -f to delete anyway"
exit 1
fi
-
- if prompts-enabled; then
- while { ps -fC $GAME_VER | awk '{ print $1" "$2"\t "$5" "$7"\t "$8" "$9" "$10 }' | grep ^"$DGL_USER"; }
- do
- echo "There are still active crawl processes running..."
- echo "-- Press RETURN to try again --"
- read
- done
-
- echo "Removing ${version} from repository..."
- echo "delete from versions where hash=\"${version}\";"| sqlite3 ${VERSIONS_DB}
- rm $BINPATH/$GAME_VER
- rm -r $BASE_DIR/$GAME_VER
- else
- if { ps -fC $GAME_VER | awk '{ print $1" "$2"\t "$5" "$7"\t "$8" "$9" "$10 }' | grep ^"$DGL_USER" >/dev/null; }
- then
- echo "Revision ${version} is being played..."
- else
- echo "Removing ${version} from repository..."
- echo "delete from versions where hash=\"${version}\";"| sqlite3 ${VERSIONS_DB}
- rm $BINPATH/$GAME_VER
- rm -r $BASE_DIR/$GAME_VER
- fi
- fi
+
+ if prompts-enabled; then
+ while { ps -fC $GAME_VER | awk '{ print $1" "$2"\t "$5" "$7"\t "$8" "$9" "$10 }' | grep ^"$DGL_USER"; }
+ do
+ echo "There are still active crawl processes running..."
+ echo "-- Press RETURN to try again --"
+ read
+ done
+
+ echo "Removing ${version} from repository..."
+ echo "delete from versions where hash=\"${version}\";"| sqlite3 ${VERSIONS_DB}
+ rm $BINPATH/$GAME_VER
+ rm -r $BASE_DIR/$GAME_VER
+ else
+ if { ps -fC $GAME_VER | awk '{ print $1" "$2"\t "$5" "$7"\t "$8" "$9" "$10 }' | grep ^"$DGL_USER" >/dev/null; }
+ then
+ echo "Revision ${version} is being played..."
+ else
+ echo "Removing ${version} from repository..."
+ echo "delete from versions where hash=\"${version}\";"| sqlite3 ${VERSIONS_DB}
+ rm $BINPATH/$GAME_VER
+ rm -r $BASE_DIR/$GAME_VER
+ fi
+ fi
else
- echo "Revision ${version} not found..."
+ echo "Revision ${version} not found..."
fi
done
echo
-exit 0
\ No newline at end of file
+exit 0
diff --git a/chroot/sbin/savegame-transfer.sh b/chroot/sbin/savegame-transfer.sh
index 164e0fed..e9badfe8 100755
--- a/chroot/sbin/savegame-transfer.sh
+++ b/chroot/sbin/savegame-transfer.sh
@@ -11,11 +11,11 @@
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
-# along with this program. If not, see .
+# along with this program. If not, see .
# ===========================================================================
#
@@ -37,9 +37,9 @@ PARAMS="$(echo "$*" | sed 's/[$*\();.|+-]//g')"
if test ${#PARAMS} -eq 0
then
- $(dirname $0)/remove-trunks.sh -v | grep -v "Usage:"
- echo "Usage: $(basename $0) [charname] ..."
- exit 1
+ $(dirname $0)/remove-trunks.sh -v | grep -v "Usage:"
+ echo "Usage: $(basename $0) [charname] ..."
+ exit 1
fi
LATEST_GAME_HASH="$(echo "select hash from versions order by time desc limit 1;" | sqlite3 ${VERSIONS_DB})"
@@ -49,61 +49,61 @@ do
CHAR_NAME="${char}"
GAME_MODE=""
PS_MOD="rc"
-
+
SAVE_FOUND="$(/bin/ls -1rt ${PREFIX}/${BINARY_MAIN_NAME}-*/saves/${CHAR_NAME}-${USER_ID}.sav ${PREFIX}/${BINARY_MAIN_NAME}-*/saves/${CHAR_NAME}-${USER_ID}.chr ${PREFIX}/${BINARY_MAIN_NAME}-*/saves/${CHAR_NAME}{-${USER_ID},}.cs 2>/dev/null | head -n 1)"
if test ${#SAVE_FOUND} -ne 0
then
- OUR_GAME_HASH="$(echo ${SAVE_FOUND} | sed "s|${PREFIX}/${BINARY_MAIN_NAME}-\(.*\)/saves/${CHAR_NAME}.*|\1|")"
- OUR_GAME_SV="$(echo select major,minor from versions where hash=\"${OUR_GAME_HASH}\"\; | sqlite3 -separator \. ${VERSIONS_DB})"
- echo -n "Char \"${CHAR_NAME}\" in ${OUR_GAME_HASH} (${OUR_GAME_SV}). "
-
- if test "${OUR_GAME_HASH}" != "${LATEST_GAME_HASH}"
- then
- OUR_SGV_MAJOR="$(echo "select major from versions where hash=\"${OUR_GAME_HASH}\";" | sqlite3 ${VERSIONS_DB})"
- POSSIBLE_GAME_HASH="$(echo "select hash from versions where major=${OUR_SGV_MAJOR} order by time desc limit 1;" | sqlite3 ${VERSIONS_DB})"
-
- if test "${OUR_GAME_HASH}" != "${POSSIBLE_GAME_HASH}"
- then
- POSSIBLE_GAME_SV="$(echo select major,minor from versions where hash=\"${POSSIBLE_GAME_HASH}\"\; | sqlite3 -separator \. ${VERSIONS_DB})"
- echo -n "Moving to ${POSSIBLE_GAME_HASH} (${POSSIBLE_GAME_SV}):"
-
- if test "$(basename ${CHAR_NAME})" != "${CHAR_NAME}"
- then
- GAME_MODE="$(dirname ${CHAR_NAME})"
- CHAR_NAME="$(basename ${CHAR_NAME})"
- PS_MOD="${GAME_MODE}"
- fi
-
- if { ps -fC ${BINARY_MAIN_NAME}-${OUR_GAME_HASH} | awk '{ print $8, $9, $10, $11 }' | grep "\-name ${CHAR_NAME} \-${PS_MOD}" &>/dev/null; }
- then
- echo -e " ${C_YELLOW}in use!${C_NORMAL}"
- continue
- fi
-
- if test -d ${PREFIX}/${BINARY_MAIN_NAME}-${POSSIBLE_GAME_HASH}/saves/${GAME_MODE}
- then
- mv -n ${PREFIX}/${BINARY_MAIN_NAME}-${OUR_GAME_HASH}/saves/${GAME_MODE}/${CHAR_NAME}* ${PREFIX}/${BINARY_MAIN_NAME}-${OUR_GAME_HASH}/saves/${GAME_MODE}/start-${CHAR_NAME}-ns.prf ${PREFIX}/${BINARY_MAIN_NAME}-${POSSIBLE_GAME_HASH}/saves/${GAME_MODE}/
- if test $? -eq 0
- then
- echo -e " ${C_GREEN}successful.${C_NORMAL}"
- else
- echo -e " ${C_RED}failed1!${C_NORMAL}"
- continue
- fi
-
- else
- echo -e " ${C_RED}failed2!${C_NORMAL}"
- continue
- fi
- else
- echo -e "${C_YELLOW}No transfer possible.${C_NORMAL}"
- fi
- else
- echo "No transfer necessary."
- fi
+ OUR_GAME_HASH="$(echo ${SAVE_FOUND} | sed "s|${PREFIX}/${BINARY_MAIN_NAME}-\(.*\)/saves/${CHAR_NAME}.*|\1|")"
+ OUR_GAME_SV="$(echo select major,minor from versions where hash=\"${OUR_GAME_HASH}\"\; | sqlite3 -separator \. ${VERSIONS_DB})"
+ echo -n "Char \"${CHAR_NAME}\" in ${OUR_GAME_HASH} (${OUR_GAME_SV}). "
+
+ if test "${OUR_GAME_HASH}" != "${LATEST_GAME_HASH}"
+ then
+ OUR_SGV_MAJOR="$(echo "select major from versions where hash=\"${OUR_GAME_HASH}\";" | sqlite3 ${VERSIONS_DB})"
+ POSSIBLE_GAME_HASH="$(echo "select hash from versions where major=${OUR_SGV_MAJOR} order by time desc limit 1;" | sqlite3 ${VERSIONS_DB})"
+
+ if test "${OUR_GAME_HASH}" != "${POSSIBLE_GAME_HASH}"
+ then
+ POSSIBLE_GAME_SV="$(echo select major,minor from versions where hash=\"${POSSIBLE_GAME_HASH}\"\; | sqlite3 -separator \. ${VERSIONS_DB})"
+ echo -n "Moving to ${POSSIBLE_GAME_HASH} (${POSSIBLE_GAME_SV}):"
+
+ if test "$(basename ${CHAR_NAME})" != "${CHAR_NAME}"
+ then
+ GAME_MODE="$(dirname ${CHAR_NAME})"
+ CHAR_NAME="$(basename ${CHAR_NAME})"
+ PS_MOD="${GAME_MODE}"
+ fi
+
+ if { ps -fC ${BINARY_MAIN_NAME}-${OUR_GAME_HASH} | awk '{ print $8, $9, $10, $11 }' | grep "\-name ${CHAR_NAME} \-${PS_MOD}" &>/dev/null; }
+ then
+ echo -e " ${C_YELLOW}in use!${C_NORMAL}"
+ continue
+ fi
+
+ if test -d ${PREFIX}/${BINARY_MAIN_NAME}-${POSSIBLE_GAME_HASH}/saves/${GAME_MODE}
+ then
+ mv -n ${PREFIX}/${BINARY_MAIN_NAME}-${OUR_GAME_HASH}/saves/${GAME_MODE}/${CHAR_NAME}* ${PREFIX}/${BINARY_MAIN_NAME}-${POSSIBLE_GAME_HASH}/saves/${GAME_MODE}/
+ if test $? -eq 0
+ then
+ echo -e " ${C_GREEN}successful.${C_NORMAL}"
+ else
+ echo -e " ${C_RED}failed1!${C_NORMAL}"
+ continue
+ fi
+
+ else
+ echo -e " ${C_RED}failed2!${C_NORMAL}"
+ continue
+ fi
+ else
+ echo -e "${C_YELLOW}No transfer possible.${C_NORMAL}"
+ fi
+ else
+ echo "No transfer necessary."
+ fi
else
- echo "Character \"${CHAR_NAME}\" not found."
+ echo "Character \"${CHAR_NAME}\" not found."
fi
done
diff --git a/config.py b/config.py
index b95265bd..c2d183a4 100644
--- a/config.py
+++ b/config.py
@@ -292,7 +292,7 @@
# If false, use traditional DES (but then only the first eight characters
# are significant).
crypt_algorithm = "6"
-# If crypt_algorithm is true, the length of the salt string to use. If
+# If crypt_algorithm is true, the length of the salt string to use. If
# crypt_algorithm is false, a two-character salt is used.
crypt_salt_length = 16
diff --git a/crawl-build/update-crawl-trunk-build.sh b/crawl-build/update-crawl-trunk-build.sh
index 93bb3fbf..17bcc491 100755
--- a/crawl-build/update-crawl-trunk-build.sh
+++ b/crawl-build/update-crawl-trunk-build.sh
@@ -68,7 +68,7 @@ if [[ "$(uname)" != "Darwin" ]] && {
ps -fC ${GAME}-${REVISION} |
awk '{ print $1" "$2"\t "$5" "$7"\t "$8" "$9" "$10 }' |
grep ^"$DGL_USER";
- }
+ }
then
abort-saying "There are already active instances of this version (${REVISION_FULL}) running"
fi
diff --git a/crawl-git.conf b/crawl-git.conf
index 960d214b..4fc8e031 100644
--- a/crawl-git.conf
+++ b/crawl-git.conf
@@ -8,7 +8,7 @@ export GAME="crawl-git"
CRAWL_BUILD_DIR=$DGL_CONF_HOME/crawl-build
CRAWL_REPOSITORY_DIR=crawl-git-repository
CRAWL_REPO=$DGL_CONF_HOME/crawl-build/$CRAWL_REPOSITORY_DIR
-CRAWL_GIT_URL=git://github.com/crawl/crawl.git
+CRAWL_GIT_URL=https://github.com/crawl/crawl.git
export CHROOT_CRAWL_BINARY_PATH="/usr/games"
export CRAWL_BINARY_PATH="$DGL_CHROOT$CHROOT_CRAWL_BINARY_PATH"
diff --git a/dgamelaunch.conf b/dgamelaunch.conf
index aaa6f2c2..c687e943 100644
--- a/dgamelaunch.conf
+++ b/dgamelaunch.conf
@@ -35,7 +35,7 @@ server_id = "DCSS Fork Collection"
# $SERVERID replaced with the server_id string, as defined above.
banner = "%%CHROOT_DGLDIR%%/data/dgl-banner"
-# The following two options are fairly insecure. They will force us to
+# The following two options are fairly insecure. They will force us to
# load the password/group database into memory while still having root
# privileges. Replace them with shed_uid/shed_gid entries as soon as
# possible if you decide to use them. dgamelaunch will inform you of
@@ -520,13 +520,13 @@ DEFINE {
game_name = "Crawl (trunk)"
short_name = "dcss-git"
- game_args = "/bin/crawl-git-launcher.sh",
+ game_args = "/bin/crawl-git-launcher.sh",
"-name", "%n",
"-rc", "%rrcfiles/crawl-git/%n.rc",
"-macro", "%rrcfiles/crawl-git/%n.macro",
"-webtiles-socket", "%%CHROOT_CRAWL_BASEDIR%%/webserver/sockets/%n:dcss-git.sock",
"-morgue", "%rmorgue/%n/"
-
+
extra_info_file = "%rmorgue/%n/%n.dglwhere"
#
@@ -558,14 +558,14 @@ DEFINE {
game_name = "Sprint (trunk)"
short_name = "spr-git"
- game_args = "/bin/crawl-git-launcher.sh",
+ game_args = "/bin/crawl-git-launcher.sh",
"-name", "%n",
"-rc", "%rrcfiles/crawl-git/%n.rc",
"-macro", "%rrcfiles/crawl-git/%n.macro",
"-webtiles-socket", "%%CHROOT_CRAWL_BASEDIR%%/webserver/sockets/%n:spr-git.sock",
"-morgue", "%rmorgue/%n/",
"-sprint"
-
+
extra_info_file = "%rmorgue/%n/%n.dglwhere"
#
@@ -597,14 +597,14 @@ DEFINE {
game_name = "Tutorial (trunk)"
short_name = "tut-git"
- game_args = "/bin/crawl-git-launcher.sh",
+ game_args = "/bin/crawl-git-launcher.sh",
"-name", "%n",
"-rc", "%rrcfiles/crawl-git/%n.rc",
"-macro", "%rrcfiles/crawl-git/%n.macro",
"-webtiles-socket", "%%CHROOT_CRAWL_BASEDIR%%/webserver/sockets/%n:tut-git.sock",
"-morgue", "%rmorgue/%n/",
"-tutorial"
-
+
extra_info_file = "%rmorgue/%n/%n.dglwhere"
#
@@ -964,7 +964,7 @@ DEFINE {
"-macro", "%rrcfiles/crawl-stoatsoup/%n.macro",
"-webtiles-socket", "%%CHROOT_CRAWL_BASEDIR%%/webserver/sockets/%n:stoatsoup.sock",
"-morgue", "%rmorgue/%n/"
-
+
extra_info_file = "%rmorgue/%n/%n.dglwhere"
#
@@ -1069,5 +1069,3 @@ DEFINE {
encoding = "UTF-8"
}
-
-
diff --git a/games.d/base.yaml b/games.d/base.yaml
new file mode 100644
index 00000000..d87e8fb4
--- /dev/null
+++ b/games.d/base.yaml
@@ -0,0 +1,2 @@
+# Empty yml file for the default dgamelaunch-config setup
+
diff --git a/help/admin.txt b/help/admin.txt
index 26290736..c73f0f68 100644
--- a/help/admin.txt
+++ b/help/admin.txt
@@ -4,4 +4,3 @@ dgl admin: Manages dgamelaunch admin users.
Usage: dgl admin ls List admin users
dgl admin add Make an admin
dgl admin rm Make a regular (non-admin) user.
-
diff --git a/utils/testing-container/Dockerfile b/utils/testing-container/Dockerfile
index a78c4fd4..a0012408 100644
--- a/utils/testing-container/Dockerfile
+++ b/utils/testing-container/Dockerfile
@@ -53,9 +53,7 @@ WORKDIR /home/crawl-dev
# TODO: what are these directories in ~crawl-dev used for? `run` doesn't exist
# on CAO?
-RUN git config --global url."https://github".insteadOf git://github
-RUN git config --global url."https://github.com".insteadOf "git://gitorious.org"
-
+RUN git config --global url.https://github.com/.insteadOf git://github.com/
# The unauthenticated git protocol on port 9418 is no longer supported.
USER crawl-dev
RUN mkdir logs \
@@ -87,6 +85,7 @@ COPY --chown=crawl-dev:crawl-dev ./chroot /home/crawl-dev/dgamelaunch-config/chr
COPY --chown=crawl-dev:crawl-dev ./crawl-build /home/crawl-dev/dgamelaunch-config/crawl-build/
COPY --chown=crawl-dev:crawl-dev ./help /home/crawl-dev/dgamelaunch-config/help/
COPY --chown=crawl-dev:crawl-dev ./lib /home/crawl-dev/dgamelaunch-config/lib/
+COPY --chown=crawl-dev:crawl-dev ./games.d /home/crawl-dev/dgamelaunch-config/games.d/
COPY --chown=crawl-dev:crawl-dev ./config.py ./crawl-git.conf ./dgamelaunch.conf ./dgl-manage.conf sh-utils /home/crawl-dev/dgamelaunch-config/
COPY --chown=crawl-dev:crawl-dev ./utils/webtiles ./utils/trigger-rebuild.pl ./utils/auth-save-downloader.pl /home/crawl-dev/dgamelaunch-config/utils/
RUN ls -al && sed -i -e 's/"127.0.0.1"/"0.0.0.0"/' /home/crawl-dev/dgamelaunch-config/config.py
diff --git a/utils/trigger-rebuild.pl b/utils/trigger-rebuild.pl
index e1d3947d..66c472b3 100755
--- a/utils/trigger-rebuild.pl
+++ b/utils/trigger-rebuild.pl
@@ -180,4 +180,3 @@ ()
}
main();
-