把schema联网结构体的虚函数更新加上 #242
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 pushes and pull requests | |
on: | |
push: | |
branches-ignore: | |
- dev | |
tags-ignore: | |
- v* | |
paths-ignore: | |
- 'README.md' | |
- 'Source2Mod-Artifacts' | |
- 'Source2Mod-Headers' | |
pull_request: | |
paths-ignore: | |
- 'README.md' | |
- 'Source2Mod-Artifacts' | |
- 'Source2Mod-Headers' | |
- 'cfg/**' | |
- 'gamedata/**' | |
- 'translations/**' | |
jobs: | |
get-version-string: | |
name: Get version string | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set vars | |
id: vars | |
run: | | |
echo "short_sha=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT | |
outputs: | |
short_sha: ${{ steps.vars.outputs.short_sha }} | |
check-newlines: | |
name: Check for CRLF and final newlines | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- run: | | |
chmod +x ./scripts/check-newlines.sh | |
./scripts/check-newlines.sh | |
check-formatting: | |
name: Check for consistent formatting | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
path: | |
- check: 'src' | |
exclude: 'sdk|protobuf' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: jidicula/[email protected] | |
with: | |
clang-format-version: '19' | |
check-path: ${{ matrix.path['check'] }} | |
exclude-regex: ${{ matrix.path['exclude'] }} | |
build-push: | |
if: ${{ github.event_name == 'push' }} | |
name: Build Push | |
uses: ./.github/workflows/build.yaml | |
needs: get-version-string | |
with: | |
version: ${{ github.ref_name }}-${{ needs.get-version-string.outputs.short_sha }} | |
build-pr: | |
if: ${{ github.event_name == 'pull_request' }} | |
name: Build PR | |
uses: ./.github/workflows/build.yaml | |
needs: get-version-string | |
with: | |
version: pr-${{ github.ref_name }}-${{ needs.get-version-string.outputs.short_sha }} |