Update packaging/releasing resources/informations
This commit is contained in:
@@ -5,10 +5,10 @@
|
||||
# all questions in this script.
|
||||
|
||||
# This is the main AssaultCube folder:
|
||||
PATHTOACDIR=~/AssaultCube/SVN_Trunk
|
||||
PATHTOACDIR=~/AssaultCube/AC
|
||||
|
||||
# This is the docs folder (which holds reference.xml):
|
||||
ABSOLUTEPATHTODOCS=~/AssaultCube/SVN_Website/htdocs/docs
|
||||
ABSOLUTEPATHTODOCS=$PATHTOACDIR/docs
|
||||
|
||||
# Path to "official" folder:
|
||||
MAPSPATH="$PATHTOACDIR/packages/maps/official"
|
||||
@@ -48,7 +48,7 @@ if [ "$1" != "--all" ]; then
|
||||
fi
|
||||
if [ "$ANSR" = "y" ] || [ "$ANSR" = "Y" ] || [ "$ANSR" = "yes" ] || [ "$ANSR" = "YES" ] || [ "$1" = "--all" ]; then
|
||||
cd $PATHTOACDIR
|
||||
sh config/convert_mapconfig.sh -osp ./packages/maps/official/*.cfg
|
||||
bash config/convert_pre_v1.2_mapconfig.sh -osp ./packages/maps/official/*.cfg
|
||||
echo -e "DONE.\n"
|
||||
else
|
||||
echo -e "\a\E[1mNOTE:\E[0m Map config files have been left alone.\n"
|
||||
@@ -60,8 +60,14 @@ if [ "$1" != "--all" ]; then
|
||||
fi
|
||||
if [ "$ANSR" = "y" ] || [ "$ANSR" = "Y" ] || [ "$ANSR" = "yes" ] || [ "$ANSR" = "YES" ] || [ "$1" = "--all" ]; then
|
||||
cd $PATHTOACDIR/config
|
||||
sed -i 's/^M$//' *
|
||||
sed -i 's/[ \t]*$//' *
|
||||
sed -i 's/^M$//' *.cfg *.txt
|
||||
sed -i 's/[ \t]*$//' *.cfg *.txt
|
||||
cd $PATHTOACDIR/config/autostart
|
||||
sed -i 's/^M$//' *.cfg *.txt
|
||||
sed -i 's/[ \t]*$//' *.cfg *.txt
|
||||
cd $PATHTOACDIR/config/opt
|
||||
sed -i 's/^M$//' *.cfg *.txt
|
||||
sed -i 's/[ \t]*$//' *.cfg *.txt
|
||||
echo -e "DONE.\n"
|
||||
else
|
||||
echo -e "\a\E[1mNOTE:\E[0m Config files haven't had leading whitespace stripped.\n"
|
||||
@@ -89,11 +95,7 @@ if [ "$ANSR" = "y" ] || [ "$ANSR" = "Y" ] || [ "$ANSR" = "yes" ] || [ "$ANSR" =
|
||||
# Replacement text for "const defaultmaps":
|
||||
DEFLTMAPS=`echo "const defaultmaps [" $MAPSLIST "]"`
|
||||
|
||||
# Replacement text for the bot silders:
|
||||
BOTSLIDER=`echo 'menuitemslider (_ [Map: ]) 0 (- (listlen $defaultmaps) 1) "$survMap" 1 [' $MAPSLIST '] [ survMap = $arg1 ]'`
|
||||
|
||||
sed -i 's/const defaultmaps..*/'"$DEFLTMAPS"'/g' menus.cfg
|
||||
sed -i 's/menuitemslider \[Map: \] 0..*/'"$BOTSLIDER"'/g' menus_bot.cfg
|
||||
echo "The following official maps are NOT listed for CTF mode currently:"
|
||||
echo $NONCTFLIST
|
||||
echo "Add a map to this list (Y/N)?"
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
#
|
||||
# update packages/misc/checksums_md5.txt
|
||||
#
|
||||
# (this script needs to be in source/dev_tools
|
||||
# (this script needs to be in source/dev_tools)
|
||||
|
||||
cd $(dirname "$(readlink -f "${0}")")
|
||||
cd ../.. # get to the base dir of the installation
|
||||
@@ -11,4 +11,3 @@ echo Generating checksums...
|
||||
find [A-z]* -type f -print0 | xargs -0 md5sum | fgrep -v checksums_md5 | fgrep -v " source/" | fgrep -v "gitignore" > packages/misc/checksums_md5.txt
|
||||
echo Done.
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,280 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Before creating compressed package complete this checklist (main points):
|
||||
# * Patch the source code/package with any relevant materials.
|
||||
# * Set the makefile to strip symbols.
|
||||
# * Compile new 32/64-bit binaries and put them in their appropriate ./bin_unix location.
|
||||
# * Delete all unnecessary files/folders.
|
||||
|
||||
# ** CHANGE THE BELOW VARIABLES BEFORE EXECUTING THE SCRIPT ** #
|
||||
|
||||
#PATHTOACDEV=$(dirname $(cd ../ && pwd))
|
||||
# Please ensure this path is NOT inside your "ACDIR" folder, as
|
||||
# this will be the place the tarball package gets saved.
|
||||
SAVETARBALLPATH=~/AssaultCube
|
||||
# This will be the directory that gets packaged:
|
||||
ACDIR=$SAVETARBALLPATH/AC
|
||||
ACDIRTESTING=$SAVETARBALLPATH/AC_testing
|
||||
ACDOCSDIR=$ACDIR/docs
|
||||
NEWACTAG=$(git describe --tags --abbrev=0)
|
||||
NEWACVERSION=$(echo $NEWACTAG |awk '{ print substr($0,2)}')
|
||||
|
||||
# KSH won't work, as this script uses echo throughout it, echo's options are shell-specific:
|
||||
if [ -z "$BASH" ]; then
|
||||
echo "FAILURE: Please run this script with BASH (bash $0), not SH/KSH/ZSH, etc."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Set auto-aliases:
|
||||
ACDIRFOLDERNAME=`basename $ACDIR`
|
||||
|
||||
# Create folder for new AC release:
|
||||
if [ ! -d "$ACDIR" ]; then
|
||||
mkdir -p "$ACDIR"
|
||||
else
|
||||
rm -r "$ACDIR"
|
||||
mkdir -p "$ACDIR"
|
||||
fi
|
||||
|
||||
# Create folder for compiling binaries for new AC release:
|
||||
if [ ! -d "$ACDIRTESTING" ]; then
|
||||
mkdir "$ACDIRTESTING"
|
||||
else
|
||||
rm -r "$ACDIRTESTING"
|
||||
mkdir "$ACDIRTESTING"
|
||||
fi
|
||||
|
||||
# Get AC files from latest local release tag:
|
||||
cd ../../
|
||||
git archive --format=tar.gz --output "$ACDIR/$NEWACTAG.tar.gz" $NEWACTAG
|
||||
cd "$ACDIR"
|
||||
tar -zxf "$ACDIR/$NEWACTAG.tar.gz"
|
||||
tar -zxf "$ACDIR/$NEWACTAG.tar.gz" -C "$ACDIRTESTING"
|
||||
rm -r "$ACDIR/$NEWACTAG.tar.gz"
|
||||
|
||||
# Use new, "portable" profile in "$ACDIRTESTING":
|
||||
sed -i 's/--home=.*\s/--home=profile /' $ACDIRTESTING/assaultcube.sh
|
||||
|
||||
# Get documentation files from latest remote release tag:
|
||||
svn export --force https://github.com/assaultcube/assaultcube.github.io/tags/$NEWACTAG/htdocs/docs/ $ACDOCSDIR
|
||||
|
||||
# Start of the script, so remind the user of things we can't check:
|
||||
echo -e "\033[1mIf required, did you patch the source with any relevant materials?\033[0m"
|
||||
echo " * Press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mDid you compile 32- and 64-bit binaries in $ACDIRTESTING and strip symbols when compiling?\033[0m"
|
||||
echo " * If so, press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mDid you renamed filenames of created binaries to linux_* and linux_64_*?\033[0m"
|
||||
echo " * If so, press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mDid you generate fresh config/mapmodelattributes.cfg (/loadallmapmodels)?\033[0m"
|
||||
echo " * If so, press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mIs the save-path in assaultcube.sh correct?\033[0m"
|
||||
echo " * If so, press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mHave you checked all following variables in this script are set correctly?\033[0m"
|
||||
echo -e " * The packages created by this script will be saved to this folder:\n $SAVETARBALLPATH"
|
||||
echo -e " * The absolute-path to your AssaultCube directory is set as:\n $ACDIR"
|
||||
echo -e " * The absolute-path to your AssaultCube \"docs\" directory is set as:\n $ACDOCSDIR"
|
||||
echo -e " * Your new AssaultCube version will become:\n $NEWACVERSION\n"
|
||||
echo -e "\033[1mIf these are correct, press ENTER to continue, otherwise press ctrl+c to exit.\033[0m"
|
||||
read DUMMY
|
||||
|
||||
# Still at the start of the script, so find user-errors that we can check:
|
||||
# Checking "$ACDIR" is set correctly:
|
||||
if [ -e $ACDIR/source/src/main.cpp ]; then
|
||||
echo "Stated path to AssaultCube contains \"source/src/main.cpp\""
|
||||
echo "Hopefully this means the path is correct and contained files are good."
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m \"source/src/main.cpp\" did NOT exist at the ACDIR alias."
|
||||
echo "Open this shell file and modify that alias to fix it."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Checking "$ACDOCSDIR" is set correctly:
|
||||
if [ -e $ACDOCSDIR/reference.xml ]; then
|
||||
echo "Stated path to AssaultCube's documentation contains \"reference.xml\""
|
||||
echo "Hopefully this means the path is correct and contained files are good."
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m \"reference.xml\" does NOT exist in %ACDOCSDIR."
|
||||
echo "Copy documentation to that folder to fix it."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that linux binaries have been created today:
|
||||
cp -v -i $ACDIRTESTING/bin_unix/linux* $ACDIR/bin_unix
|
||||
checkbinaries() {
|
||||
BINARYFILES=`cd $ACDIR/bin_unix && find ./linux_* -mtime 0 | sort | xargs`
|
||||
}
|
||||
checkbinaries
|
||||
until [ "$BINARYFILES" = "./linux_64_client ./linux_64_server ./linux_client ./linux_server" ]; do
|
||||
echo -e "\033[1;31mERROR:\033[0m Timestamps on binary files are older than 24 hours or they're missing."
|
||||
echo "Please add new 32/64-bit binaries."
|
||||
read DUMMY
|
||||
checkbinaries
|
||||
done
|
||||
echo "All binaries have been compiled in the last 24 hours. Hopefully this means they're up to date!"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
|
||||
# Check that config/mapmodelattributes.cfg has been created today:
|
||||
cp -v -i $ACDIRTESTING/profile/config/mapmodelattributes.cfg $ACDIR/config
|
||||
checkmapmodelsattr() {
|
||||
MAPMODELATTRFILE=`cd $ACDIR/config && find ./mapmodelattributes.cfg -mtime 0 | xargs`
|
||||
}
|
||||
checkmapmodelsattr
|
||||
until [ "$MAPMODELATTRFILE" = "./mapmodelattributes.cfg" ]; do
|
||||
echo -e "\033[1;31mERROR:\033[0m Timestamp on config/mapmodelattributes.cfg is older than 24 hours or it's missing."
|
||||
echo "Please add fresh config/mapmodelattributes.cfg file."
|
||||
read DUMMY
|
||||
checkmapmodelsattr
|
||||
done
|
||||
echo "config/mapmodelattributes.cfg has been generated in the last 24 hours. Hopefully this means it's up to date!"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
|
||||
# Check that shadows.dat files exist. To grab a list of shadows.dat files:
|
||||
# cd ./packages/models && find . -name "shadows.dat" | sort
|
||||
echo -e "\033[1mDid you copy shadow files (*.dat) from another working AC installation into $ACDIR?\033[0m"
|
||||
echo -e " * If not, they will be automatically copied from $ACDIRTESTING"
|
||||
echo " * Press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
cd $ACDIR/packages/models/
|
||||
ACDIRMODELS_SHADOWS=$ACDIRTESTING/profile/packages/models
|
||||
if [ ! -e ./misc/gib01/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/misc/gib01/shadows.dat $(pwd)/misc/gib01/shadows.dat; fi
|
||||
if [ ! -e ./misc/gib02/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/misc/gib02/shadows.dat $(pwd)/misc/gib02/shadows.dat; fi
|
||||
if [ ! -e ./misc/gib03/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/misc/gib03/shadows.dat $(pwd)/misc/gib03/shadows.dat; fi
|
||||
if [ ! -e ./pickups/akimbo/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/pickups/akimbo/shadows.dat $(pwd)/pickups/akimbo/shadows.dat; fi
|
||||
if [ ! -e ./pickups/ammobox/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/pickups/ammobox/shadows.dat $(pwd)/pickups/ammobox/shadows.dat; fi
|
||||
if [ ! -e ./pickups/health/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/pickups/health/shadows.dat $(pwd)/pickups/health/shadows.dat; fi
|
||||
if [ ! -e ./pickups/helmet/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/pickups/helmet/shadows.dat $(pwd)/pickups/helmet/shadows.dat; fi
|
||||
if [ ! -e ./pickups/kevlar/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/pickups/kevlar/shadows.dat $(pwd)/pickups/kevlar/shadows.dat; fi
|
||||
if [ ! -e ./pickups/nade/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/pickups/nade/shadows.dat $(pwd)/pickups/nade/shadows.dat; fi
|
||||
if [ ! -e ./pickups/pistolclips/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/pickups/pistolclips/shadows.dat $(pwd)/pickups/pistolclips/shadows.dat; fi
|
||||
if [ ! -e ./playermodels/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/playermodels/shadows.dat $(pwd)/playermodels/shadows.dat; fi
|
||||
if [ ! -e ./weapons/assault/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/assault/world/shadows.dat $(pwd)/weapons/assault/world/shadows.dat; fi
|
||||
if [ ! -e ./weapons/carbine/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/carbine/world/shadows.dat $(pwd)/weapons/carbine/world/shadows.dat; fi
|
||||
if [ ! -e ./weapons/grenade/static/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/grenade/static/shadows.dat $(pwd)/weapons/grenade/static/shadows.dat; fi
|
||||
if [ ! -e ./weapons/grenade/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/grenade/world/shadows.dat $(pwd)/weapons/grenade/world/shadows.dat; fi
|
||||
if [ ! -e ./weapons/knife/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/knife/world/shadows.dat $(pwd)/weapons/knife/world/shadows.dat; fi
|
||||
if [ ! -e ./weapons/pistol/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/pistol/world/shadows.dat $(pwd)/weapons/pistol/world/shadows.dat; fi
|
||||
if [ ! -e ./weapons/shotgun/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/shotgun/world/shadows.dat $(pwd)/weapons/shotgun/world/shadows.dat; fi
|
||||
if [ ! -e ./weapons/sniper/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/sniper/world/shadows.dat $(pwd)/weapons/sniper/world/shadows.dat; fi
|
||||
if [ ! -e ./weapons/subgun/world/shadows.dat ]; then cp -v $ACDIRMODELS_SHADOWS/weapons/subgun/world/shadows.dat $(pwd)/weapons/subgun/world/shadows.dat; fi
|
||||
|
||||
until [ -f ./misc/gib01/shadows.dat ] \
|
||||
&& [ -f ./misc/gib02/shadows.dat ] \
|
||||
&& [ -f ./misc/gib03/shadows.dat ] \
|
||||
&& [ -f ./pickups/akimbo/shadows.dat ] \
|
||||
&& [ -f ./pickups/ammobox/shadows.dat ] \
|
||||
&& [ -f ./pickups/health/shadows.dat ] \
|
||||
&& [ -f ./pickups/helmet/shadows.dat ] \
|
||||
&& [ -f ./pickups/kevlar/shadows.dat ] \
|
||||
&& [ -f ./pickups/nade/shadows.dat ] \
|
||||
&& [ -f ./pickups/pistolclips/shadows.dat ] \
|
||||
&& [ -f ./playermodels/shadows.dat ] \
|
||||
&& [ -f ./weapons/assault/world/shadows.dat ] \
|
||||
&& [ -f ./weapons/carbine/world/shadows.dat ] \
|
||||
&& [ -f ./weapons/grenade/static/shadows.dat ] \
|
||||
&& [ -f ./weapons/grenade/world/shadows.dat ] \
|
||||
&& [ -f ./weapons/knife/world/shadows.dat ] \
|
||||
&& [ -f ./weapons/pistol/world/shadows.dat ] \
|
||||
&& [ -f ./weapons/shotgun/world/shadows.dat ] \
|
||||
&& [ -f ./weapons/sniper/world/shadows.dat ] \
|
||||
&& [ -f ./weapons/subgun/world/shadows.dat ]; do
|
||||
echo -e "\033[1;31mERROR:\033[0m Some shadows.dat files are missing."
|
||||
echo "Please run AssaultCube to generate these files."
|
||||
read DUMMY
|
||||
done
|
||||
echo "All known shadows.dat files exist."
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
|
||||
# Check that map previews are all available:
|
||||
MAPSPATH="$ACDIR/packages/maps/official"
|
||||
MAPSCGZ=`cd $MAPSPATH && find ./*.cgz | xargs -i basename {} .cgz | sort -u | xargs`
|
||||
MAPSJPG=`cd $MAPSPATH/preview && find ./*.jpg | xargs -i basename {} .jpg | sort -u | xargs`
|
||||
if [ "$MAPSCGZ" = "$MAPSJPG" ]; then
|
||||
echo "All map \"previews\" are available!"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m Some map previews are missing."
|
||||
echo "Please go to $MAPSPATH/preview and create the ones that are missing!"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that bot waypoints are all available:
|
||||
MAPSCGZ2=`cd $MAPSPATH && find ./*.cgz | xargs -i basename {} .cgz | sort -u | xargs`
|
||||
MAPSBOTS=`cd $ACDIR/bot/waypoints && find ./*.wpt | xargs -i basename {} .wpt | sort -u | xargs`
|
||||
if [ "$MAPSBOTS" = "$MAPSCGZ2" ]; then
|
||||
echo "All bot waypoints are available!"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m Some bot waypoints are missing."
|
||||
echo "Please go generate the ones that are missing!"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Delete stuff related to git and GitHub:
|
||||
rm -rf ./.git
|
||||
rm -f ./.gitattributes
|
||||
rm -f ./.travis.yml
|
||||
find . -type f -name ".gitignore" -delete
|
||||
# Delete gedit backups:
|
||||
find . -type f -name "*~" -delete
|
||||
|
||||
# Create config template for release:
|
||||
cd $ACDIR/config
|
||||
zip configtemplates.zip autoexec.cfg favourites.cfg pcksources.cfg
|
||||
|
||||
# Clean out crufty files:
|
||||
echo "Please wait: Cleaning out some crufty files..."
|
||||
cd $ACDIR/source/enet && make distclean
|
||||
cd ../src && make clean
|
||||
rm -f init*.cfg saved*.cfg servervita*.cfg servers.cfg history
|
||||
rm -f ./clientlog*.txt
|
||||
rm -f ./bin_unix/native_*
|
||||
rm -f ./bin_unix/ac_*
|
||||
rm -f ./packages/maps/dev_*.cgz
|
||||
rm -f ./packages/maps/dev_*.cfg
|
||||
rm -f ./packages/maps/servermaps/incoming/*.cgz
|
||||
rm -f ./packages/maps/servermaps/incoming/*.cfg
|
||||
rm -f ./screenshots/*
|
||||
# Leave tutorial code here, just in case of future use:
|
||||
cd $ACDIR && rm -f `(find ./demos/* -type f | grep -v "tutorial_demo.dmo")`
|
||||
|
||||
# Set up ./config/securemaps.cfg - just in-case:
|
||||
echo "... Generating ./config/securemaps.cfg"
|
||||
echo "resetsecuremaps" > ./config/securemaps.cfg
|
||||
find ./packages/maps/official/*.cgz | \
|
||||
xargs -i basename {} .cgz | \
|
||||
xargs -i echo -e "securemap" {} | \
|
||||
sort -u >> ./config/securemaps.cfg
|
||||
|
||||
# update checksum file:
|
||||
sh $ACDIR/source/dev_tools/generate_md5_checksums.sh
|
||||
|
||||
# Create the linux tarball:
|
||||
echo "\n... Creating the Linux tarball..."
|
||||
cd $SAVETARBALLPATH
|
||||
if [ -d "AssaultCube_v$NEWACVERSION" ]; then
|
||||
rm -r "AssaultCube_v$NEWACVERSION"
|
||||
fi
|
||||
mv $ACDIRFOLDERNAME AssaultCube_v$NEWACVERSION
|
||||
tar cjvf $SAVETARBALLPATH/AssaultCube_v$NEWACVERSION.tar.bz2 \
|
||||
--exclude=".*" \
|
||||
--exclude=*.bat \
|
||||
--exclude=*bin_win32* \
|
||||
--exclude=*doxygen* \
|
||||
--exclude="*source/lib*" \
|
||||
--exclude=*vcpp* \
|
||||
--exclude=*xcode* \
|
||||
--exclude=*AssaultCube.cbp \
|
||||
--exclude=*autoexec.cfg \
|
||||
--exclude=*favourites.cfg \
|
||||
--exclude=*pcksources.cfg \
|
||||
--exclude=*new_content.cfg \
|
||||
--exclude=*new_content.cgz \
|
||||
--exclude-vcs \
|
||||
AssaultCube_v$NEWACVERSION/
|
||||
@@ -0,0 +1,28 @@
|
||||
Packaging AssaultCube:
|
||||
|
||||
I. Part 1:
|
||||
|
||||
1. Make sure that all steps from releasing_guide.txt are done.
|
||||
2. Do "git archive" for the latest release tag (preferred) or download ZIP package of "master" branch from GitHub or do fresh "git clone" (don't start AC afterwards to avoid any changes).
|
||||
3. Extract the archive to the AssaultCube folder purposed to packaging.
|
||||
4. Extract the archive to the second folder in different location and:
|
||||
a) compile there binaries of client and server, change potential "native_*" filenames to "ac_*" filenames on Windows or to "linux_*" filenames on Linux, test binaries;
|
||||
b) generate fresh config/mapmodelattributes.cfg file: delete config/mapmodelattributes.cfg (if existent), run AC with an empty profile (important: packages/models/mapmodels in profile has to be empty) and run /loadallmapmodels command;
|
||||
c) copy freshly generated config/mapmodelattributes.cfg file to the folder purposed to packaging, also copy there binaries to the bin_*/ folder for the target platform;
|
||||
d) copy shadow files (*.dat) from another working AC installation (for example from this, which was used to compile and test binaries or from dev version of AC) to the folder purposed to packaging.
|
||||
|
||||
II. Part 2 - concerns AssaultCube folder purposed to packaging:
|
||||
|
||||
1. Copy the whole content from htdocs/docs/ folder in the latest release tag in assaultcube.github.io repository to docs/ folder.
|
||||
2. Delete .git folder, .gitignore, .travis.yml, if existent.
|
||||
3. Archive config/autoexec.cfg, config/favourites.cfg, config/pcksources.cfg into config/configtemplates.zip (see commit 41fd31d).
|
||||
4. Delete the whole source/ folder, but only then, if you prepare .exe, .dmg etc. installer (generally at least for Windows and Mac). DON'T delete it, if compressed archive/package is prepared on Linux, instead of that delete source/doxygen/, source/vcpp/, source/xcode/, source/lib/ folders and source/codeblocks/AssaultCube.cbp file.
|
||||
5. Delete config/autoexec.cfg, config/favourites.cfg, config/pcksources.cfg, config/init*.cfg, config/saved*.cfg, config/servervita*.cfg, config/servers.cfg, config/history, clientlog*.txt, packages/maps/*.cgz and .cfg, packages/maps/servermaps/incoming/*.cgz and .cfg, if existent.
|
||||
6. Delete contents of screenshots/ folder.
|
||||
7. Delete contents of demos/ folder, besides tutorial_demo.dmo, if existent.
|
||||
8. Delete for Windows all remaining *.sh files, and for Linux and Mac all remaining *.bat files. Delete the bin_*/ folders that are not needed on the target platform.
|
||||
9. Generate checksum file packages/misc/checksums_md5.txt, with use source/dev_tools/generate_md5_checksums.* script (generally at least on Linux).
|
||||
10. Package AC (.exe/.tar.bz2/etc.) and name it like AssaultCube_vMAJOR.MINOR.BUILD.REVISION.EXTENSION - on Windows this could be AssaultCube_v1.0.0.0.exe
|
||||
11. Create new release on GitHub and upload there packages and sources.
|
||||
|
||||
These steps can be automatized, see source/vcpp/buildEnv/*.bat and source/dev_tools/*.sh for examples.
|
||||
@@ -0,0 +1,25 @@
|
||||
Last steps/commits/actions effected in releasing new AssaultCube version:
|
||||
|
||||
Note: changes should be commited.
|
||||
|
||||
I. Documentation ("assaultcube.github.io" repository):
|
||||
|
||||
1. Change everywhere number of AC version, date in copyrights info, release notes, uninstall notes, changelog, download page (download links are predicable on GitHub), etc.
|
||||
2. Add release tag (vMAJOR.MINOR.BUILD.REVISION) to the "master" branch in assaultcube.github.io repository.
|
||||
3. Synchronise local and remote "master" branches in assaultcube.github.io repository.
|
||||
|
||||
II. AssaultCube ("AC" repository - "master" branch):
|
||||
|
||||
1. Transform docs/reference.xml in assaultcube.github.io repository into docs.cfg, copy it to config/ folder in AC repository.
|
||||
2. Make sure that config/pcksources.cfg contains only trusted package source servers, if not, update them.
|
||||
3. Replace maps in packages/maps/official folder by newer dev_* maps from packages/maps/ folder.
|
||||
4. Check, whether in packages/maps/official/preview/ folder there are preview .jpg files for new official maps, if missing, add them.
|
||||
5. Check, whether in bot/waypoint/ folder there are files with bot waypoints for new official maps, if missing, add them.
|
||||
6. Update official maps list in config/: menus.cfg, securemaps.cfg, etc.
|
||||
7. Change everywhere number of AC version, date in copyrights informations. Note: on Mac number of version is also saved in binary file English.lproj/InfoPlist.strings .
|
||||
8. Change everywhere path to profile to assaultcube/v.MAJOR.MINOR .
|
||||
9. Change protocol number, if necessary.
|
||||
10. Update changelog.txt file.
|
||||
11. Add release tag (vMAJOR.MINOR.BUILD.REVISION) to the "master" branch in AC repository.
|
||||
12. Synchronise local and remote "master" branches in AC repository.
|
||||
|
||||
@@ -1,203 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Before running this script, complete this checklist:
|
||||
# * Download a copy of current GIT.
|
||||
# * Download a copy of current GIT documentation files.
|
||||
# * Patch the source code/package with any relevant materials.
|
||||
# * Set the makefile to strip symbols.
|
||||
# * Compile new 32/64 bit binaries and put them in their appropriate ./bin_unix locations.
|
||||
# (this isn't done automatically, as I compile the 32-bit binary on a virtual machine).
|
||||
# * Delete all non-repository files/folders except any shadows.dat and the new binaries.
|
||||
|
||||
# ** CHANGE THE BELOW 4 VARIABLES BEFORE EXECUTING THE SCRIPT ** #
|
||||
|
||||
# Please ensure this path is NOT inside your "PATHTOACDIR" folder, as
|
||||
# this will be the place the tarball package gets saved.
|
||||
SAVETARBALLPATH=~/AssaultCube
|
||||
# This will be the directory that gets packaged:
|
||||
PATHTOACDIR=~/AssaultCube/GIT_AC
|
||||
ABSOLUTEPATHTODOCS=~/AssaultCube/GIT_Website/htdocs/docs
|
||||
NEWACVERSION=1.2.0.2
|
||||
|
||||
# KSH won't work, as this script uses echo throughout it, echo's options are shell-specific:
|
||||
if [ -z "$(echo "$BASH")" ]; then
|
||||
echo "FAILURE: Please run this script with BASH, not SH/KSH/ZSH, etc"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Set auto-aliases:
|
||||
ACDIRFOLDERNAME=`basename $PATHTOACDIR`
|
||||
|
||||
# Start of the script, so remind the user of things we can't check:
|
||||
echo -e "\n\033[1mThe following files have changed, since your last update from GIT:\033[0m"
|
||||
cd "$PATHTOACDIR" && git fetch && git diff --name-status master origin/master
|
||||
cd "$ABSOLUTEPATHTODOCS" && git fetch && git diff --name-status master origin/master
|
||||
echo -e "\n\033[1mThe following files are not in GIT, but exist locally:\033[0m"
|
||||
cd "$PATHTOACDIR" && git ls-files --other --exclude-standard
|
||||
cd "$ABSOLUTEPATHTODOCS" && git ls-files --other --exclude-standard
|
||||
echo " * If you're happy with this, press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mIf required, did you patch the source with any relevant materials?\033[0m"
|
||||
echo " * Press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mDid you strip symbols when compiling?\033[0m"
|
||||
echo " * If so, press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mIs the save-path in assaultcube.sh correct?\033[0m"
|
||||
echo " * If so, press ENTER to continue, otherwise press ctrl+c to exit."
|
||||
read DUMMY
|
||||
echo -e "\033[1mHave you checked all 4 variables in this script are set correctly?\033[0m"
|
||||
echo -e " * The packages created by this script will be saved to this folder:\n $SAVETARBALLPATH"
|
||||
echo -e " * The absolute-path to your AssaultCube directory is set as:\n $PATHTOACDIR"
|
||||
echo -e " * The absolute-path to your AssaultCube \"docs\" directory is set as:\n $ABSOLUTEPATHTODOCS"
|
||||
echo -e " * Your new AssaultCube version will become:\n $NEWACVERSION\n"
|
||||
echo -e "\033[1mIf these are correct, press ENTER to continue, otherwise press ctrl+c to exit.\033[0m"
|
||||
read DUMMY
|
||||
|
||||
# Still at the start of the script, so find user-errors that we can check:
|
||||
# Checking "$ABSOLUTEPATHTODOCS" is set correctly...
|
||||
if [ -e $ABSOLUTEPATHTODOCS/reference.xml ]; then
|
||||
echo "Stated path to AssaultCube's documentation contains \"reference.xml\""
|
||||
echo "Hopefully this means the path is correct and contained files are good."
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m \"reference.xml\" did NOT exist at the ABSOLUTEPATHTODOCS alias."
|
||||
echo "Open this shell file and modify that alias to fix it."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Checking "$PATHTOACDIR" is set correctly...
|
||||
if [ -e $PATHTOACDIR/source/src/main.cpp ]; then
|
||||
echo "Stated path to AssaultCube contains \"source/src/main.cpp\""
|
||||
echo "Hopefully this means the path is correct and contained files are good."
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m \"source/src/main.cpp\" did NOT exist at the PATHTOACDIR alias."
|
||||
echo "Open this shell file and modify that alias to fix it."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Checking for "xsltproc"...
|
||||
if [ -n "$(command -v xsltproc)" ]; then
|
||||
echo "The 'xsltproc' program exists. This means we can generate docs.cfg"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m 'xsltproc' doesn't exist."
|
||||
echo "Please install xsltproc so docs.cfg can be generated."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that linux binaries have been created today:
|
||||
BINARYFILES=`cd $PATHTOACDIR/bin_unix && find ./linux_* -mtime 0 | sort | xargs`
|
||||
if [ "$BINARYFILES" = "./linux_64_client ./linux_64_server ./linux_client ./linux_server" ]; then
|
||||
echo "All binaries have been compiled in the last 24 hours. Hopefully this means they're up to date!"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m Timestamps on binary files are older than 24 hours."
|
||||
echo "Please go compile new 32/64 bit binaries."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that map previews are all available:
|
||||
MAPSPATH="$PATHTOACDIR/packages/maps/official"
|
||||
MAPSCGZ=`cd $MAPSPATH && find ./*.cgz | xargs -i basename {} .cgz | sort -u | xargs`
|
||||
MAPSJPG=`cd $MAPSPATH/preview && find ./*.jpg | xargs -i basename {} .jpg | sort -u | xargs`
|
||||
if [ "$MAPSCGZ" = "$MAPSJPG" ]; then
|
||||
echo "All map \"previews\" are available!"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m Some map previews are missing."
|
||||
echo "Please go to $MAPSPATH/preview and create the ones that are missing!"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that bot waypoints are all available:
|
||||
MAPSCGZ2=`cd $MAPSPATH && find ./*.cgz | xargs -i basename {} .cgz | sort -u | xargs`
|
||||
MAPSBOTS=`cd $PATHTOACDIR/bot/waypoints && find ./*.wpt | xargs -i basename {} .wpt | sort -u | xargs`
|
||||
if [ "$MAPSBOTS" = "$MAPSCGZ2" ]; then
|
||||
echo "All bot waypoints are available!"
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m Some bot waypoints are missing."
|
||||
echo "Please go generate the ones that are missing!"
|
||||
exit
|
||||
fi
|
||||
|
||||
# Check that shadows.dat files exist. To grab a list of shadows.dat files:
|
||||
# cd ./packages/models && find . -name "shadows.dat" | sort
|
||||
cd $PATHTOACDIR/packages/models/
|
||||
if [ -e ./misc/gib02/shadows.dat ] \
|
||||
&& [ -e ./misc/gib03/shadows.dat ] \
|
||||
&& [ -e ./pickups/akimbo/shadows.dat ] \
|
||||
&& [ -e ./pickups/ammobox/shadows.dat ] \
|
||||
&& [ -e ./pickups/health/shadows.dat ] \
|
||||
&& [ -e ./pickups/helmet/shadows.dat ] \
|
||||
&& [ -e ./pickups/kevlar/shadows.dat ] \
|
||||
&& [ -e ./pickups/nade/shadows.dat ] \
|
||||
&& [ -e ./pickups/pistolclips/shadows.dat ] \
|
||||
&& [ -e ./playermodels/shadows.dat ] \
|
||||
&& [ -e ./weapons/assault/world/shadows.dat ] \
|
||||
&& [ -e ./weapons/carbine/world/shadows.dat ] \
|
||||
&& [ -e ./weapons/grenade/static/shadows.dat ] \
|
||||
&& [ -e ./weapons/grenade/world/shadows.dat ] \
|
||||
&& [ -e ./weapons/knife/world/shadows.dat ] \
|
||||
&& [ -e ./weapons/pistol/world/shadows.dat ] \
|
||||
&& [ -e ./weapons/shotgun/world/shadows.dat ] \
|
||||
&& [ -e ./weapons/sniper/world/shadows.dat ] \
|
||||
&& [ -e ./weapons/subgun/world/shadows.dat ]; then
|
||||
echo "All known shadows.dat files exist."
|
||||
echo -e "Proceeding to the next step...\n"
|
||||
else
|
||||
echo -e "\033[1;31mERROR:\033[0m Some shadows.dat files are missing."
|
||||
echo "Please run AssaultCube to generate these files."
|
||||
exit
|
||||
fi
|
||||
|
||||
# Clean out crufty files:
|
||||
echo "Please wait: Cleaning out some crufty files..."
|
||||
cd $PATHTOACDIR/source/enet && make distclean
|
||||
cd ../src && make clean
|
||||
cd ../../config && rm -f init.cfg killmessages.cfg saved.cfg servers.cfg
|
||||
echo -e "// This file gets executed every time you start AssaultCube. \n\n// This is where you should put any scripts you may have created for AC." > autoexec.cfg
|
||||
# Leave tutorial code here, just in case of future use:
|
||||
cd .. && rm -f `(find ./demos/* -type f | grep -v "tutorial_demo.dmo")`
|
||||
rm -f ./bin_unix/native_*
|
||||
rm -f ./packages/maps/*.cgz
|
||||
rm -f ./screenshots/*
|
||||
# Delete gedit backups:
|
||||
find . -type f -name "*~" -delete
|
||||
|
||||
# Copy docs over:
|
||||
echo "Copied documentation into the main folder..."
|
||||
cd $PATHTOACDIR && cp $ABSOLUTEPATHTODOCS/* $PATHTOACDIR/docs/ -R
|
||||
|
||||
# Set up ./config/docs.cfg - just in-case:
|
||||
echo "... Generating ./config/docs.cfg"
|
||||
xsltproc -o ./config/docs.cfg ./docs/xml/cuberef2cubescript.xslt ./docs/reference.xml
|
||||
|
||||
# Set up ./config/securemaps.cfg - just in-case:
|
||||
echo "... Generating ./config/securemaps.cfg"
|
||||
echo "resetsecuremaps" > ./config/securemaps.cfg
|
||||
find ./packages/maps/official/*.cgz | \
|
||||
xargs -i basename {} .cgz | \
|
||||
xargs -i echo -e "securemap" {} | \
|
||||
sort -u >> ./config/securemaps.cfg
|
||||
|
||||
# update checksum file
|
||||
$PATHTOACDIR/source/dev_tools/generate_md5_checksums.sh
|
||||
|
||||
# Create the linux tarball:
|
||||
echo -e "\n... Creating the Linux tarball..."
|
||||
cd .. && mv $ACDIRFOLDERNAME AssaultCube_v$NEWACVERSION
|
||||
tar cjvf $SAVETARBALLPATH/AssaultCube_v$NEWACVERSION.tar.bz2 \
|
||||
--exclude=".*" \
|
||||
--exclude=*.bat --exclude=*bin_win32* \
|
||||
--exclude=*xcode* \
|
||||
--exclude=*vcpp* \
|
||||
--exclude=*new_content.cfg \
|
||||
--exclude=*new_content.cgz \
|
||||
--exclude-vcs \
|
||||
AssaultCube_v$NEWACVERSION/
|
||||
|
||||
# Clean up:
|
||||
cd $PATHTOACDIR && git clean -fdx && git reset --hard
|
||||
@@ -1,14 +0,0 @@
|
||||
Packaging AssaultCube:
|
||||
|
||||
1. fresh svn checkout (Don't start AC afterwards to avoid any changes)
|
||||
2. delete config/saved.cfg if existent
|
||||
3. make sure config/servers.cfg is empty
|
||||
4. delete contents of folder screenshots/
|
||||
5. delete contents of folder demos/
|
||||
6. delete the whole source/ folder
|
||||
7. delete the whole docs/autogen/ folder
|
||||
8. Copy shadow files (.dat) from another working AC installation (SVN) into the freshly exported directory
|
||||
9. Delete the bin_*/ folders that are not needed by your platform
|
||||
10.Package AC (.exe/.tgz/etc) and name it like AssaultCube_vMAJOR.MINOR.BUILD.REVISION.FORMAT on Windows this could be AssaultCube_v1.0.0.0.exe
|
||||
|
||||
This steps can be automatized, see source\vcpp\buildEnv\*.bat for examples.
|
||||
@@ -60,7 +60,7 @@ SetCompressor /SOLID lzma
|
||||
!define AC_URLPROTOCOL "assaultcube"
|
||||
!define AC_MAJORVERSIONINT 1
|
||||
!define AC_MINORVERSIONINT 2
|
||||
!define AC_NEWVERSIONDIR "ac" ; directory with prepared new AC version
|
||||
!define AC_NEWVERSIONDIR "AC" ; directory with prepared new AC version
|
||||
; path to profile folder in "MYDOCUMENTS" directory, should be the same as in assaultcube.bat
|
||||
!define AC_PROFILEPATH "My Games\AssaultCube\v${AC_MAJORVERSIONINT}.${AC_MINORVERSIONINT}"
|
||||
|
||||
@@ -484,6 +484,7 @@ Section "Uninstall"
|
||||
RMDir "$INSTDIR\demos"
|
||||
RMDir /r "$INSTDIR\docs"
|
||||
Delete "$INSTDIR\mods\ac_mods_README.html"
|
||||
Delete "$INSTDIR\mods\protox_hq_reskin.zip"
|
||||
RMDir "$INSTDIR\mods"
|
||||
RMDir /r "$INSTDIR\packages"
|
||||
RMDir "$INSTDIR\screenshots"
|
||||
|
||||
@@ -364,7 +364,7 @@ Section "AssaultCube ${AC_FULLVERSION} Update" PATCH
|
||||
|
||||
SetOutPath "$INSTDIR"
|
||||
|
||||
File /r ac_patch\*.*
|
||||
File /r AC_patch\*.*
|
||||
|
||||
SectionEnd
|
||||
|
||||
|
||||
@@ -1,25 +1,26 @@
|
||||
rem add new release tag to master branch of AssaulCube and documentation before start of AC installer preparing
|
||||
rem local branches should be compatible with remote
|
||||
rem you need to have installed 7-Zip and Subversion and added 7z.exe and svn.exe to PATH
|
||||
set acdir=ac
|
||||
set acdircompiled=ac_compiled
|
||||
if not exist "%acdir%\" (mkdir %acdir%) else (rmdir /S /Q %acdir% & mkdir %acdir%)
|
||||
if not exist "%acdircompiled%\" (mkdir %acdircompiled%) else (rmdir /S /Q %acdircompiled% & mkdir %acdircompiled%)
|
||||
set ACDIR=AC
|
||||
set ACDIRTESTING=AC_testing
|
||||
if not exist "%ACDIR%\" (mkdir %ACDIR%) else (rmdir /S /Q %ACDIR% & mkdir %ACDIR%)
|
||||
if not exist "%ACDIRTESTING%\" (mkdir %ACDIRTESTING%) else (rmdir /S /Q %ACDIRTESTING% & mkdir %ACDIRTESTING%)
|
||||
|
||||
rem get tag with name of latest AC version
|
||||
git describe --tags --abbrev=0 > tmpFile
|
||||
set /p latest= < tmpFile
|
||||
set /p NEWACTAG= < tmpFile
|
||||
del tmpFile
|
||||
|
||||
rem get AC files from latest local release tag
|
||||
cd ..\..\..\
|
||||
git archive --format zip --output source\vcpp\buildEnv\%acdir%\%latest%.zip %latest%
|
||||
cd source\vcpp\buildEnv\%acdir%
|
||||
7z x %latest%.zip
|
||||
7z x %latest%.zip -o..\%acdircompiled%
|
||||
del %latest%.zip
|
||||
git archive --format zip --output source\vcpp\buildEnv\%ACDIR%\%NEWACTAG%.zip experimental
|
||||
cd source\vcpp\buildEnv\%ACDIR%
|
||||
7z x %NEWACTAG%.zip
|
||||
7z x %NEWACTAG%.zip -o..\%ACDIRTESTING%
|
||||
del ..\%ACDIRTESTING%\assaultcube.bat
|
||||
del %NEWACTAG%.zip
|
||||
|
||||
rem get documentation files from latest remote release tag
|
||||
svn export --force https://github.com/assaultcube/assaultcube.github.io/tags/%latest%/htdocs/docs/ docs
|
||||
svn export --force https://github.com/assaultcube/assaultcube.github.io/tags/%NEWACTAG%/htdocs/docs/ docs
|
||||
|
||||
pause
|
||||
|
||||
@@ -1,67 +1,76 @@
|
||||
@echo off
|
||||
set acdir=ac
|
||||
set workingacdir=..\..\..\
|
||||
set ACDIR=AC
|
||||
set ACDIRTESTING=AC_testing
|
||||
|
||||
rem delete stuff related to git and GitHub
|
||||
rmdir /S /Q %acdir%\.git
|
||||
del %acdir%\.gitattributes
|
||||
del %acdir%\.travis.yml
|
||||
for /r %acdir% %%i in (*) do if "%%~nxi"==".gitignore" del "%%i"
|
||||
echo make sure, that you compiled new binaries in %ACDIRTESTING% folder, tested them and generated fresh config\mapmodelattributes.cfg file (/loadallmapmodels)
|
||||
pause
|
||||
|
||||
rem delete config and logs
|
||||
del %acdir%\config\init*.cfg
|
||||
del %acdir%\config\saved*.cfg
|
||||
del %acdir%\config\servervita*.cfg
|
||||
del %acdir%\config\servers.cfg
|
||||
del %acdir%\config\history
|
||||
del %acdir%\clientlog*.txt
|
||||
rem copy binaries
|
||||
copy /Y %ACDIRTESTING%\bin_win32\ac_* %ACDIR%\bin_win32\
|
||||
|
||||
rem create config template
|
||||
7z a -tzip -aoa %acdir%\config\configtemplates.zip .\%acdir%\config\autoexec.cfg .\%acdir%\config\favourites.cfg .\%acdir%\config\pcksources.cfg
|
||||
del %acdir%\config\autoexec.cfg
|
||||
del %acdir%\config\favourites.cfg
|
||||
del %acdir%\config\pcksources.cfg
|
||||
|
||||
rem delete map files
|
||||
del %acdir%\packages\maps\*.cgz
|
||||
del %acdir%\packages\maps\*.cfg
|
||||
del %acdir%\packages\maps\servermaps\incoming\*.cgz
|
||||
del %acdir%\packages\maps\servermaps\incoming\*.cfg
|
||||
|
||||
rem purge screenshots
|
||||
del /Q %acdir%\screenshots\*
|
||||
|
||||
rem purge demo directory, but leave tutorial demo, just in case of future use
|
||||
for %%i in (%acdir%\demos\*) do if not "%%~nxi"=="tutorial_demo.dmo" del /Q "%%i"
|
||||
|
||||
rem remove linux stuff
|
||||
del %acdir%\*.sh
|
||||
del %acdir%\config\*.sh
|
||||
rmdir /S /Q %acdir%\bin_unix
|
||||
|
||||
rem remove source files (those are available in the source pkg)
|
||||
rmdir /S /Q %acdir%\source
|
||||
rem copy mapmodelattributes.cfg
|
||||
copy /Y %ACDIRTESTING%\profile\config\mapmodelattributes.cfg %ACDIR%\config\
|
||||
|
||||
rem copy shadow files
|
||||
copy /Y %workingacdir%\packages\models\misc\gib01\shadows.dat %acdir%\packages\models\misc\gib01\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\misc\gib02\shadows.dat %acdir%\packages\models\misc\gib02\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\misc\gib03\shadows.dat %acdir%\packages\models\misc\gib03\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\pickups\akimbo\shadows.dat %acdir%\packages\models\pickups\akimbo\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\pickups\ammobox\shadows.dat %acdir%\packages\models\pickups\ammobox\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\pickups\health\shadows.dat %acdir%\packages\models\pickups\health\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\pickups\helmet\shadows.dat %acdir%\packages\models\pickups\helmet\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\pickups\kevlar\shadows.dat %acdir%\packages\models\pickups\kevlar\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\pickups\nade\shadows.dat %acdir%\packages\models\pickups\nade\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\pickups\pistolclips\shadows.dat %acdir%\packages\models\pickups\pistolclips\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\playermodels\shadows.dat %acdir%\packages\models\playermodels\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\assault\world\shadows.dat %acdir%\packages\models\weapons\assault\world\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\carbine\world\shadows.dat %acdir%\packages\models\weapons\carbine\world\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\grenade\static\shadows.dat %acdir%\packages\models\weapons\grenade\static\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\grenade\world\shadows.dat %acdir%\packages\models\weapons\grenade\world\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\knife\world\shadows.dat %acdir%\packages\models\weapons\knife\world\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\pistol\world\shadows.dat %acdir%\packages\models\weapons\pistol\world\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\shotgun\world\shadows.dat %acdir%\packages\models\weapons\shotgun\world\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\sniper\world\shadows.dat %acdir%\packages\models\weapons\sniper\world\shadows.dat
|
||||
copy /Y %workingacdir%\packages\models\weapons\subgun\world\shadows.dat %acdir%\packages\models\weapons\subgun\world\shadows.dat
|
||||
set ACDIRMODELS_SHADOWS=%ACDIRTESTING%\profile\packages\models
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\misc\gib01\shadows.dat %ACDIR%\packages\models\misc\gib01\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\misc\gib02\shadows.dat %ACDIR%\packages\models\misc\gib02\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\misc\gib03\shadows.dat %ACDIR%\packages\models\misc\gib03\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\pickups\akimbo\shadows.dat %ACDIR%\packages\models\pickups\akimbo\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\pickups\ammobox\shadows.dat %ACDIR%\packages\models\pickups\ammobox\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\pickups\health\shadows.dat %ACDIR%\packages\models\pickups\health\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\pickups\helmet\shadows.dat %ACDIR%\packages\models\pickups\helmet\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\pickups\kevlar\shadows.dat %ACDIR%\packages\models\pickups\kevlar\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\pickups\nade\shadows.dat %ACDIR%\packages\models\pickups\nade\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\pickups\pistolclips\shadows.dat %ACDIR%\packages\models\pickups\pistolclips\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\playermodels\shadows.dat %ACDIR%\packages\models\playermodels\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\assault\world\shadows.dat %ACDIR%\packages\models\weapons\assault\world\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\carbine\world\shadows.dat %ACDIR%\packages\models\weapons\carbine\world\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\grenade\static\shadows.dat %ACDIR%\packages\models\weapons\grenade\static\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\grenade\world\shadows.dat %ACDIR%\packages\models\weapons\grenade\world\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\knife\world\shadows.dat %ACDIR%\packages\models\weapons\knife\world\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\pistol\world\shadows.dat %ACDIR%\packages\models\weapons\pistol\world\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\shotgun\world\shadows.dat %ACDIR%\packages\models\weapons\shotgun\world\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\sniper\world\shadows.dat %ACDIR%\packages\models\weapons\sniper\world\shadows.dat
|
||||
copy /Y %ACDIRMODELS_SHADOWS%\weapons\subgun\world\shadows.dat %ACDIR%\packages\models\weapons\subgun\world\shadows.dat
|
||||
|
||||
rem delete stuff related to git and GitHub
|
||||
rmdir /S /Q %ACDIR%\.git
|
||||
del %ACDIR%\.gitattributes
|
||||
del %ACDIR%\.travis.yml
|
||||
for /r %ACDIR% %%i in (*) do if "%%~nxi"==".gitignore" del "%%i"
|
||||
|
||||
rem create config template
|
||||
7z a -tzip -aoa %ACDIR%\config\configtemplates.zip %ACDIR%\config\autoexec.cfg %ACDIR%\config\favourites.cfg %ACDIR%\config\pcksources.cfg
|
||||
|
||||
rem remove source files (those are available in the source pkg)
|
||||
rmdir /S /Q %ACDIR%\source
|
||||
|
||||
rem delete config and logs
|
||||
del %ACDIR%\config\autoexec.cfg
|
||||
del %ACDIR%\config\favourites.cfg
|
||||
del %ACDIR%\config\pcksources.cfg
|
||||
del %ACDIR%\config\init*.cfg
|
||||
del %ACDIR%\config\saved*.cfg
|
||||
del %ACDIR%\config\servervita*.cfg
|
||||
del %ACDIR%\config\servers.cfg
|
||||
del %ACDIR%\config\history
|
||||
del %ACDIR%\clientlog*.txt
|
||||
|
||||
rem delete map files
|
||||
del %ACDIR%\packages\maps\*.cgz
|
||||
del %ACDIR%\packages\maps\*.cfg
|
||||
del %ACDIR%\packages\maps\servermaps\incoming\*.cgz
|
||||
del %ACDIR%\packages\maps\servermaps\incoming\*.cfg
|
||||
|
||||
rem purge screenshots
|
||||
del /Q %ACDIR%\screenshots\*
|
||||
|
||||
rem purge demo directory, but leave tutorial demo, just in case of future use
|
||||
for %%i in (%ACDIR%\demos\*) do if not "%%~nxi"=="tutorial_demo.dmo" del /Q "%%i"
|
||||
|
||||
rem remove linux stuff
|
||||
for /r %ACDIR% %%i in (*.sh) do del "%%i"
|
||||
rmdir /S /Q %ACDIR%\bin_unix
|
||||
|
||||
pause
|
||||
|
||||
@@ -600,7 +600,7 @@
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 1;
|
||||
shellPath = /bin/sh;
|
||||
shellScript = "echo $TARGET_BUILD_DIR\ncd $TARGET_BUILD_DIR\n\n#ensure old package is gone\nrm -f assaultcube.dmg\n\n#make the directory which our disk image will be made of\n#use /tmp as a destination because copying ourself (xcode folder) whilst compiling causes the dog to chase its tail\nACPKG=`mktemp -d /tmp/acpkg.XXXXXX` || exit 1\n\n#leave indicator of where temp directory is in case things break\nln -sf $ACPKG $TARGET_BUILD_DIR/acpkg\n\n#copy launcher\n/usr/bin/CpMac -r $TARGET_BUILD_DIR/launcher.app $ACPKG/AssaultCube.app\n\nHELPDIR=$ACPKG/AssaultCube.app/Contents/Resources/help/\nGAMEDIR=$ACPKG/AssaultCube.app/Contents/gamedata\nmkdir $GAMEDIR\nmkdir $HELPDIR\n\n#copy assaultcube\n/usr/bin/CpMac -r $TARGET_BUILD_DIR/assaultcube.app $GAMEDIR/\nstrip -u -r \"$GAMEDIR/assaultcube.app/Contents/MacOS/assaultcube\"\n\n#copy readme and data and remove unneccesary stuff\n/usr/bin/CpMac -r $SRCROOT/../../README.html $HELPDIR/\n/usr/bin/CpMac -r $SRCROOT/../../changelog.txt $HELPDIR/\n/usr/bin/CpMac -r $SRCROOT/../../docs $HELPDIR/\n/usr/bin/CpMac -r $SRCROOT/../../bot $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../config $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../demos $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../mods $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../packages $GAMEDIR/\nmkdir $GAMEDIR/screenshots\n#/Developer/Tools/CpMac -r $SRCROOT/../../source $ACPKG/sourcecode\n#rm -rf $ACPKG/sourcecode/xcode/build\n#rm -rf $ACPKG/sourcecode/xcode/DerivedData\n#rm -rf $ACPKG/sourcecode/xcode/Frameworks/*\n#rm -rf $ACPKG/sourcecode/vcpp\n\n#clean up\nfind -d $ACPKG -name \"shadows.dat\" -exec rm -rf {} \\;\nrm -f `(find -d $GAMEDIR/demos -type f | grep -v \"tutorial_demo.dmo\")`\nrm -f $GAMEDIR/packages/maps/new_content.cgz\nrm -f $GAMEDIR/packages/maps/new_content.cfg\nfind $ACPKG -name \".DS_Store\" -exec rm -f {} \\;\nfind -d $ACPKG -name \".gitignore\" -exec rm -rf {} \\;\nrm -rf $GAMEDIR/.git\nrm -f $GAMEDIR/.gitattributes\nrm -f $GAMEDIR/.travis.yml\nrm -rf $HELPDIR/docs/autogen/\n\n#create config template\ncd $GAMEDIR/config\nzip configtemplates.zip autoexec.cfg favourites.cfg pcksources.cfg\nrm -f autoexec.cfg favourites.cfg pcksources.cfg init*.cfg saved*.cfg servervita*.cfg servers.cfg history\ncd $TARGET_BUILD_DIR\n\n#add alias to readme\n/usr/bin/osascript <<EOT\ntell application \"Finder\"\nset macSrcPath to POSIX file \"$HELPDIR/README.html\" as text\nset macDestPath to POSIX file \"$ACPKG\" as text\nmake new alias file to file macSrcPath at folder macDestPath\nend tell\nEOT\n\n#finally make a disk image out of the stuff\nhdiutil create -srcfolder $ACPKG -volname assaultcube assaultcube.dmg\nhdiutil internet-enable -yes assaultcube.dmg\n\n#cleanup\nrm -rf $ACPKG";
|
||||
shellScript = "echo $TARGET_BUILD_DIR\ncd $TARGET_BUILD_DIR\n\n#ensure old package is gone\nrm -f assaultcube.dmg\n\n#make the directory which our disk image will be made of\n#use /tmp as a destination because copying ourself (xcode folder) whilst compiling causes the dog to chase its tail\nACPKG=`mktemp -d /tmp/acpkg.XXXXXX` || exit 1\n\n#leave indicator of where temp directory is in case things break\nln -sf $ACPKG $TARGET_BUILD_DIR/acpkg\n\n#copy launcher\n/usr/bin/CpMac -r $TARGET_BUILD_DIR/launcher.app $ACPKG/AssaultCube.app\n\nHELPDIR=$ACPKG/AssaultCube.app/Contents/Resources/help/\nGAMEDIR=$ACPKG/AssaultCube.app/Contents/gamedata\nmkdir $GAMEDIR\nmkdir $HELPDIR\n\n#copy assaultcube\n/usr/bin/CpMac -r $TARGET_BUILD_DIR/assaultcube.app $GAMEDIR/\nstrip -u -r \"$GAMEDIR/assaultcube.app/Contents/MacOS/assaultcube\"\n\n#copy readme and data and remove unneccesary stuff\n/usr/bin/CpMac -r $SRCROOT/../../README.html $HELPDIR/\n/usr/bin/CpMac -r $SRCROOT/../../changelog.txt $HELPDIR/\n/usr/bin/CpMac -r $SRCROOT/../../docs $HELPDIR/\n/usr/bin/CpMac -r $SRCROOT/../../bot $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../config $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../demos $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../mods $GAMEDIR/\n/usr/bin/CpMac -r $SRCROOT/../../packages $GAMEDIR/\n#mkdir $GAMEDIR/screenshots\n\n#create config template\ncd $GAMEDIR/config\nzip configtemplates.zip autoexec.cfg favourites.cfg pcksources.cfg\n\n#clean up\nrm -rf $GAMEDIR/.git\nrm -f $GAMEDIR/.gitattributes\nrm -f $GAMEDIR/.travis.yml\nfind -d $ACPKG -name \".gitignore\" -exec rm -rf {} \\;\nrm -rf $HELPDIR/docs/autogen/\nfind $ACPKG -name \".DS_Store\" -exec rm -f {} \\;\n\nfind -d $ACPKG -name \"shadows.dat\" -exec rm -rf {} \\;\nrm -f autoexec.cfg favourites.cfg pcksources.cfg init*.cfg saved*.cfg servervita*.cfg servers.cfg history\nrm -f $GAMEDIR/clientlog*.txt\nrm -f $GAMEDIR/packages/maps/*.cgz\nrm -f $GAMEDIR/packages/maps/*.cfg\nrm -f $GAMEDIR/packages/maps/servermaps/incoming/*.cgz\nrm -f $GAMEDIR/packages/maps/servermaps/incoming/*.cfg\nrm -f `(find -d $GAMEDIR/demos -type f | grep -v \"tutorial_demo.dmo\")`\n \n#/Developer/Tools/CpMac -r $SRCROOT/../../source $ACPKG/sourcecode\n#rm -rf $ACPKG/sourcecode/xcode/build\n#rm -rf $ACPKG/sourcecode/xcode/DerivedData\n#rm -rf $ACPKG/sourcecode/xcode/Frameworks/*\n#rm -rf $ACPKG/sourcecode/vcpp\n\ncd $TARGET_BUILD_DIR\n\n#add alias to readme\n/usr/bin/osascript <<EOT\ntell application \"Finder\"\nset macSrcPath to POSIX file \"$HELPDIR/README.html\" as text\nset macDestPath to POSIX file \"$ACPKG\" as text\nmake new alias file to file macSrcPath at folder macDestPath\nend tell\nEOT\n\n#finally make a disk image out of the stuff\nhdiutil create -srcfolder $ACPKG -volname assaultcube assaultcube.dmg\nhdiutil internet-enable -yes assaultcube.dmg\n\n#cleanup\nrm -rf $ACPKG";
|
||||
};
|
||||
/* End PBXShellScriptBuildPhase section */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user