3 - if: $CI_COMMIT_MESSAGE =~ /Transifex autosync/
\r
8 - ln -s $PWD data/xonotic-data.pk3dir
\r
10 - export MAKEFLAGS=-j$(nproc); echo MAKEFLAGS=$MAKEFLAGS
\r
11 # FIXME: -march=native -mtune=native _changes the hash_, why?!?
\r
12 # - export CC="gcc -pipe -march=native -mtune=native"
\r
13 - export CC="gcc -pipe"
\r
15 - git clone --depth=1 --branch=main https://gitlab.com/xonotic/gmqcc.git gmqcc
\r
16 - make -C gmqcc || exit 1
\r
17 - export QCC="$PWD/gmqcc/gmqcc"
\r
19 test_compilation_units:
\r
30 - git clone --depth=1 --branch=div0-stable https://gitlab.com/xonotic/darkplaces.git darkplaces
\r
31 - make -C darkplaces sv-release || exit 1
\r
32 - export ENGINE="$PWD/darkplaces/darkplaces-dedicated -xonotic -noconfig -nohome"
\r
35 - mkdir -p data/maps
\r
36 - wget -O data/maps/gitlab-ci.bsp https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/_init/_init.bsp
\r
38 - while read LINE; do
\r
40 [ "$LINE" = "All tests OK" ] && PASS=1;
\r
41 done < <(${ENGINE} +developer 1 +map gitlab-ci +sv_cmd runtest +wait +quit)
\r
42 - test "$PASS" = "1" || { echo 'sv_cmd runtest failed!'; exit 1; }
\r
44 - ${ENGINE} +map gitlab-ci +sv_cmd dumpnotifs +wait +quit
\r
45 - diff notifications.cfg data/data/notifications_dump.cfg ||
\r
46 { echo 'Please update notifications.cfg using `dumpnotifs`!'; exit 1; }
\r
48 - wget -O data/stormkeep.pk3 http://beta.xonotic.org/autobuild-bsp/latest/stormkeep.pk3
\r
49 - wget -O data/maps/stormkeep.mapinfo https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.mapinfo
\r
50 - wget -O data/maps/stormkeep.waypoints https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.waypoints
\r
51 - wget -O data/maps/stormkeep.waypoints.cache https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.waypoints.cache
\r
53 - EXPECT=d4060caf37a2e60bab68d1f83bc57368
\r
54 - HASH=$(${ENGINE} +timestamps 1 +exec serverbench.cfg
\r
56 | sed -e 's,^\[[^]]*\] ,,'
\r
58 | grep -v '^:gamestart:'
\r
59 | grep -v '^:anticheat:'
\r
60 | md5sum | awk '{ print $1 }')
\r
61 - echo 'expected:' $EXPECT
\r
62 - echo ' actual:' $HASH
\r
63 - test "$HASH" == "$EXPECT"
\r
67 # NOTE: The generated docs are incomplete - they don't contain code behind SVQC CSQC MENUQC GAMEQC ifdefs.
\r
68 # With them added to PREDEFINED, it would take over half an hour to generate the docs and even then
\r
69 # they might not be complete. Doxygen doesn't handle #elif and might not understand some QC definitions.
\r
70 #doxygen: # rename to 'pages' when gitlab.com allows pages to exceed 100MiB
\r
72 # - ln -s $PWD data/xonotic-data.pk3dir # is this needed?
\r
74 # - apt-get -y install doxygen graphviz
\r
77 # - cd qcsrc && doxygen
\r
78 # - mv html ../public
\r
80 # - for i in {0..0}; do eval $(printf "echo \$id_rsa_%02d\n" $i) >> ~/.ssh/id_rsa_base64; done
\r
81 # - base64 --decode ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
\r
82 # - chmod 600 ~/.ssh/id_rsa
\r
83 # - echo -e "Host *\n\tStrictHostKeyChecking no\n\tLogLevel ERROR\n" >> ~/.ssh/config
\r
84 # - git config --global user.name "Gitlab CI"
\r
85 # - git config --global user.email "<>"
\r
86 # - git clone --single-branch --depth 1 ${DEPLOY_HOST}:${DEPLOY_REPO} ~/deploy_
\r
87 # - mkdir ~/deploy && mv ~/deploy_/.git ~/deploy && rm -r ~/deploy_
\r
88 # - cp -r ../public/* ~/deploy
\r
89 # - cd ~/deploy && git add -A . && git commit -m "Deploy ${CI_BUILD_REF}" && git push origin gh-pages
\r