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=master 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/g-23.pk3 http://beta.xonotic.org/autobuild-bsp/latest/g-23.pk3
28 - wget -O data/maps/g-23.mapinfo https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/g-23.mapinfo
29 - wget -O data/maps/g-23.waypoints https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/g-23.waypoints
30 - wget -O data/maps/g-23.waypoints.cache https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/g-23.waypoints.cache
31 - wget -O data/maps/g-23.waypoints.hardwired https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/g-23.waypoints.hardwired
33 - EXPECT=04d63df6a5d73bd335612543efd944d6
34 - HASH=$(${ENGINE} -noconfig -nohome +exec serverbench.cfg
37 | grep -v '^:gamestart:'
38 | grep -v '^:anticheat:'
39 | md5sum | awk '{ print $1 }')
40 - echo 'expected:' $EXPECT
41 - echo ' actual:' $HASH
42 - test "$HASH" == "$EXPECT"
48 - git clone --depth=1 --branch=master https://gitlab.com/xonotic/darkplaces.git darkplaces
49 - cd darkplaces && make sv-debug -j $(nproc) && export ENGINE="$PWD/darkplaces-dedicated -xonotic"
52 - mkdir maps && wget -O maps/gitlab-ci.bsp https://gitlab.com/xonotic/xonotic-maps.pk3dir/raw/master/maps/_init/_init.bsp
56 if [[ $line == "All tests OK" ]]; then exit 0; fi;
57 done < <(${ENGINE} +developer 1 +map gitlab-ci +sv_cmd runtest +exit)
60 doxygen: # rename to 'pages' when gitlab.com allows pages to exceed 100MiB
65 - for i in {0..0}; do eval $(printf "echo \$id_rsa_%02d\n" $i) >> ~/.ssh/id_rsa_base64; done
66 - base64 --decode ~/.ssh/id_rsa_base64 > ~/.ssh/id_rsa
67 - chmod 600 ~/.ssh/id_rsa
68 - echo -e "Host *\n\tStrictHostKeyChecking no\n\tLogLevel ERROR\n" >> ~/.ssh/config
69 - git config --global user.name "Gitlab CI"
70 - git config --global user.email "<>"
71 - git clone --single-branch --depth 1 ${DEPLOY_HOST}:${DEPLOY_REPO} ~/deploy_
72 - mkdir ~/deploy && mv ~/deploy_/.git ~/deploy && rm -r ~/deploy_
73 - cp -r ../public/* ~/deploy
74 - cd ~/deploy && git add -A . && git commit -m "Deploy ${CI_BUILD_REF}" && git push origin gh-pages