Upload *.smx #7
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: Compile with SourceMod | |
on: | |
pull_request: | |
branches: master | |
push: | |
branches: master | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set environment variables | |
run: echo SCRIPTS_PATH=$(pwd) >> $GITHUB_ENV | |
- name: Setup SourcePawn Compiler ${{ matrix.SM_VERSION }} | |
id: setup_sp | |
uses: rumblefrog/setup-sp@master | |
with: | |
version: '1.11.x' | |
- name: Checkout neotokyo include repo | |
uses: actions/checkout@v4 | |
with: | |
repository: softashell/sourcemod-nt-include | |
path: sourcemod-nt-include | |
- name: Compile plugins | |
run: | | |
for file in ./scripting/*.sp | |
do | |
echo -e "\nCompiling $file..." | |
spcomp -E -w234 -O2 -v2 -i ./scripting/include -i ./sourcemod-nt-include/scripting/include $file | |
done | |
echo "===OUT FILES===" | |
ls *.smx | |
working-directory: ${{ env.SCRIPTS_PATH }} | |
- name: Upload compiled plugins | |
uses: actions/upload-artifact@v4 | |
with: | |
name: compiled-plugins | |
path: | | |
*.smx | |
release: | |
needs: build | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
steps: | |
- uses: actions/download-artifact@v4 | |
with: | |
name: compiled-plugins | |
path: release | |
- name: Display structure of downloaded files | |
run: ls -R | |
- name: Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
tag_name: release | |
files: | | |
./release/*.smx |