2 - ln -s $PWD data/xonotic-data.pk3dir
4 - git clone --depth=1 --branch=master https://gitlab.com/xonotic/gmqcc.git gmqcc
5 - cd gmqcc && make -j $(nproc) && export QCC="$PWD/gmqcc"
11 - cloc --force-lang-def=qcsrc/tools/cloc.txt --sql 1 --sql-project xonotic qcsrc | sqlite3 code.db
12 - sqlite3 code.db 'select file,nCode from t where nCode > 1000 order by nBlank+nComment+nCode desc'
14 test_compilation_units:
17 - ./qcsrc/tools/compilationunits.sh
22 - git clone --depth=1 --branch=div0-stable https://gitlab.com/xonotic/darkplaces.git darkplaces
23 - cd darkplaces && make sv-debug -j $(nproc) && export ENGINE="$PWD/darkplaces-dedicated -xonotic"
27 - wget -O data/stormkeep.pk3 http://beta.xonotic.org/autobuild-bsp/latest/stormkeep.pk3
28 - wget -O data/maps/stormkeep.mapinfo https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.mapinfo
29 - wget -O data/maps/stormkeep.waypoints https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.waypoints
30 - wget -O data/maps/stormkeep.waypoints.cache https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/stormkeep.waypoints.cache
32 - EXPECT=e1e069b401a7aaf28fed29e2e8cbc0c8
33 - HASH=$(${ENGINE} -noconfig -nohome +exec serverbench.cfg
36 | grep -v '^:gamestart:'
37 | grep -v '^:anticheat:'
38 | md5sum | awk '{ print $1 }')
39 - echo 'expected:' $EXPECT
40 - echo ' actual:' $HASH
41 - test "$HASH" == "$EXPECT"
47 - git clone --depth=1 --branch=div0-stable https://gitlab.com/xonotic/darkplaces.git darkplaces
48 - cd darkplaces && make sv-debug -j $(nproc) && export ENGINE="$PWD/darkplaces-dedicated -xonotic"
51 - mkdir maps && wget -O maps/gitlab-ci.bsp https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/_init/_init.bsp
55 if [[ $line == "All tests OK" ]]; then exit 0; fi;
56 done < <(${ENGINE} +developer 1 +map gitlab-ci +sv_cmd runtest +exit)
59 doxygen: # rename to 'pages' when gitlab.com allows pages to exceed 100MiB
64 - for i in {0..0}; do eval $(printf "echo \$id_rsa_%02d\n" $i) >> ~/.ssh/id_rsa_base64; done
65 - base64 --decode ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
66 - chmod 600 ~/.ssh/id_rsa
67 - echo -e "Host *\n\tStrictHostKeyChecking no\n\tLogLevel ERROR\n" >> ~/.ssh/config
68 - git config --global user.name "Gitlab CI"
69 - git config --global user.email "<>"
70 - git clone --single-branch --depth 1 ${DEPLOY_HOST}:${DEPLOY_REPO} ~/deploy_
71 - mkdir ~/deploy && mv ~/deploy_/.git ~/deploy && rm -r ~/deploy_
72 - cp -r ../public/* ~/deploy
73 - cd ~/deploy && git add -A . && git commit -m "Deploy ${CI_BUILD_REF}" && git push origin gh-pages