Add CBotProfile operator= and fix squad bounds check #118
This file contains hidden or 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: Build | |
| on: ["push", "workflow_dispatch"] | |
| jobs: | |
| build_main: | |
| name: Build for ${{ matrix.os_short }} | |
| runs-on: ${{ matrix.os_version }} | |
| # skip build on '[ci skip]' | |
| if: "!contains(github.event.head_commit.message, '[ci skip]')" | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: | |
| #- ubuntu-22.04 # appears to no longer work - especially forcing using GCC instead of Clang | |
| - ubuntu-latest | |
| - windows-x32 | |
| - windows-x64 | |
| include: | |
| #- os: ubuntu-22.04 | |
| # os_short: linux-legacy | |
| # os_version: ubuntu-22.04 | |
| # package_ext: tar.gz | |
| # dbg_ext: dbg | |
| # cc: gcc | |
| # cxx: g++ | |
| # vs_arch: unused | |
| # am_arch: x86,x86_64 | |
| - os: ubuntu-latest | |
| os_short: linux-latest | |
| os_version: ubuntu-latest | |
| package_ext: tar.gz | |
| dbg_ext: dbg | |
| cc: clang | |
| cxx: clang++ | |
| vs_arch: unused | |
| am_arch: x86,x86_64 | |
| - os: windows-x32 | |
| os_short: win32 | |
| os_version: windows-latest | |
| package_ext: zip | |
| dbg_ext: pdb | |
| cc: not-used | |
| cxx: not-used | |
| vs_arch: x32 | |
| am_arch: x86 | |
| - os: windows-x64 | |
| os_short: win64 | |
| os_version: windows-latest | |
| package_ext: zip | |
| dbg_ext: pdb | |
| cc: not-used | |
| cxx: not-used | |
| vs_arch: x64 | |
| am_arch: x86_64 | |
| steps: | |
| - name: Install (Linux) | |
| if: runner.os == 'Linux' | |
| run: | | |
| sudo dpkg --add-architecture i386 | |
| sudo apt-get update | |
| sudo apt-get install -y clang g++-multilib | |
| echo "CC=${{ matrix.cc }}" >> $GITHUB_ENV | |
| echo "CXX=${{ matrix.cxx }}" >> $GITHUB_ENV | |
| - name: Add msbuild to PATH (Windows) | |
| if: runner.os == 'Windows' | |
| uses: microsoft/setup-msbuild@v3 | |
| - name: Install (Windows) | |
| if: runner.os == 'Windows' | |
| shell: cmd | |
| run: | | |
| :: See https://github.com/microsoft/vswhere/wiki/Find-VC | |
| for /f "usebackq delims=*" %%i in (`vswhere -latest -property installationPath`) do ( | |
| call "%%i"\Common7\Tools\vsdevcmd.bat -arch=${{ matrix.vs_arch }} -host_arch=x64 | |
| ) | |
| :: Loop over all environment variables and make them global. | |
| for /f "delims== tokens=1,2" %%a in ('set') do ( | |
| echo>>"%GITHUB_ENV%" %%a=%%b | |
| ) | |
| - name: Setup Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: '3.12' | |
| - name: Setup ambuild | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install wheel | |
| pip install git+https://github.com/alliedmodders/ambuild | |
| - name: Fetch RCBot2 | |
| uses: actions/checkout@v6 | |
| with: | |
| path: rcbot2 | |
| submodules: recursive | |
| - name: Build Files | |
| working-directory: rcbot2 | |
| run: | | |
| mkdir post | |
| cd post | |
| python3 ../configure.py --sdks=present --mms-path="${{ github.workspace }}/rcbot2/alliedmodders/metamod-source" --sm-path="${{ github.workspace }}/rcbot2/alliedmodders/sourcemod" --hl2sdk-root="${{ github.workspace }}/rcbot2/alliedmodders" --symbol-files --target ${{ matrix.am_arch }} --enable-optimize | |
| ambuild | |
| - uses: benjlevesque/short-sha@v3.0 | |
| id: short-sha | |
| - name: Upload Binary | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: rcbot2-${{ matrix.os_short }}-${{ steps.short-sha.outputs.sha }} | |
| path: | | |
| rcbot2/post/package/* | |
| - name: Upload Debug Symbols | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: rcbot2-dbgsym-${{ matrix.os_short }}-${{ steps.short-sha.outputs.sha }} | |
| path: | | |
| rcbot2/post/**/*.${{ matrix.dbg_ext }} | |
| combine_windows: | |
| name: Combine Windows Builds | |
| needs: build_main | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: benjlevesque/short-sha@v3.0 | |
| id: short-sha | |
| - name: Download Win32 artifact | |
| uses: actions/download-artifact@v7 | |
| with: | |
| name: rcbot2-win32-${{ steps.short-sha.outputs.sha }} | |
| path: combined/win32 | |
| - name: Download Win64 artifact | |
| uses: actions/download-artifact@v7 | |
| with: | |
| name: rcbot2-win64-${{ steps.short-sha.outputs.sha }} | |
| path: combined/win64 | |
| - name: Upload Combined Windows Artifact | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: rcbot2-windows-${{ steps.short-sha.outputs.sha }} | |
| path: combined/ | |
| - name: Download Win32 Debug Symbols | |
| uses: actions/download-artifact@v7 | |
| with: | |
| name: rcbot2-dbgsym-win32-${{ steps.short-sha.outputs.sha }} | |
| path: combined-dbgsym/win32 | |
| - name: Download Win64 Debug Symbols | |
| uses: actions/download-artifact@v7 | |
| with: | |
| name: rcbot2-dbgsym-win64-${{ steps.short-sha.outputs.sha }} | |
| path: combined-dbgsym/win64 | |
| - name: Upload Combined Windows Debug Symbols | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: rcbot2-dbgsym-windows-${{ steps.short-sha.outputs.sha }} | |
| path: combined-dbgsym/ | |
| - name: Delete Individual Windows Artifacts | |
| uses: geekyeggo/delete-artifact@v6 | |
| with: | |
| name: | | |
| rcbot2-win32-${{ steps.short-sha.outputs.sha }} | |
| rcbot2-win64-${{ steps.short-sha.outputs.sha }} | |
| rcbot2-dbgsym-win32-${{ steps.short-sha.outputs.sha }} | |
| rcbot2-dbgsym-win64-${{ steps.short-sha.outputs.sha }} |