Wait Period rewrite + Black Mesa Chapter 1-3 EDT improvements #205
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
pull_request: | |
push: | |
branches: master | |
jobs: | |
build: | |
name: "Build" | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
game: | |
- { dir: bms, args: "SRCCOOP_BLACKMESA=1" } | |
- { dir: hl2mp, args: "SRCCOOP_HL2DM=1" } | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
- name: Setup sourcemod compiler | |
id: setup-sp | |
uses: rumblefrog/setup-sp@master | |
with: | |
version: '1.12.7163' | |
version-file: ./scripting/include/srccoop/public.inc | |
define-name: SRCCOOP_VERSION | |
- name: Compile plugins | |
run: | | |
mkdir -p plugins/disabled/srccoop_debug | |
for file in scripting/*.sp | |
do | |
plugin="$(basename "${file%.*}")" | |
echo -e "\nCompiling $plugin\n" | |
spcomp -v2 -i scripting/include -o plugins/"$plugin".smx "$file" NO_DEBUG=1 ${{ matrix.game.args }} | |
spcomp -v2 -i scripting/include -o plugins/disabled/srccoop_debug/"$plugin".smx "$file" ${{ matrix.game.args }} | |
done | |
- name: Create package | |
run: | | |
OUT="/tmp/srccoop" | |
SM="${OUT}/addons/sourcemod" | |
EDT_DEST="${SM}/data/srccoop" | |
mkdir -p $SM | |
mkdir -p $EDT_DEST | |
cp -R extensions $SM | |
cp -R plugins $SM | |
cp -R configs $SM | |
cp -R gamedata $SM | |
cp -R scripting $SM | |
cp -R translations $SM | |
cp -R data $SM | |
cp -R edt/common/. $EDT_DEST | |
if [ -d "edt/${{ matrix.game.dir }}" ] | |
then | |
cp -R edt/${{ matrix.game.dir }}/. $EDT_DEST | |
fi | |
cp -R gamecontent/common/. $OUT | |
if [ -d "gamecontent/${{ matrix.game.dir }}" ] | |
then | |
cp -R gamecontent/${{ matrix.game.dir }}/. $OUT | |
fi | |
: # prune any development files | |
find $OUT -type f -name ".gitignore" -delete | |
: # print package tree | |
tree -a $OUT | |
- name: Upload package | |
uses: actions/upload-artifact@v4 | |
with: | |
name: SourceCoop-${{ steps.setup-sp.outputs.plugin-version }}-${{ matrix.game.dir }}-build${{ github.run_number }} | |
path: /tmp/srccoop/ |