Deploy #73
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: Deploy | |
on: | |
push: | |
branches-ignore: | |
- 'no-ci-**' | |
- 'skip-ci-**' | |
pull_request: | |
schedule: | |
- cron: '0 0 * * 0' | |
env: | |
# common settings | |
CMAKE_VERSION: 3.21.x | |
# paths | |
ci_native_sdk_name: rebelfork-sdk-Linux-clang-rel-dll-x64-latest.zip | |
ci_source_dir: ${{ github.workspace }}/source-code | |
ci_build_script: ./source-code/Script/ci_build.sh | |
ci_build_dir: ${{ github.workspace }}/cmake-build | |
ci_sdk_dir: ${{ github.workspace }}/SDK | |
jobs: | |
CheckSkipCI: | |
runs-on: ubuntu-20.04 | |
if: | | |
!contains(github.event.head_commit.message, '[skip ci]') && | |
!contains(github.event.pull_request.title, '[skip ci]') && | |
!contains(github.event.head_commit.message, '[skip-ci]') && | |
!contains(github.event.pull_request.title, '[skip-ci]') | |
steps: | |
- run: exit 0 | |
Web: | |
if: github.event.pull_request.draft == false | |
runs-on: ubuntu-20.04 | |
needs: [CheckSkipCI] | |
strategy: | |
fail-fast: false | |
matrix: | |
ci_emsdk_version: | |
- latest | |
env: | |
BINARYEN_CORES: 1 | |
steps: | |
- uses: mymindstorm/setup-emsdk@v11 | |
with: | |
version: ${{ matrix.ci_emsdk_version }} | |
- name: Checkout Sample Project | |
uses: actions/checkout@v2 | |
with: | |
path: ${{ env.ci_source_dir }} | |
fetch-depth: 1 | |
submodules: true | |
- name: Checkout the Framework | |
uses: actions/checkout@v2 | |
with: | |
repository: rbfx/rbfx | |
path: ${{ env.ci_source_dir }}/../rbfx | |
fetch-depth: 1 | |
submodules: true | |
- name: Download native SDK | |
uses: robinraju/[email protected] | |
with: | |
repository: rbfx/rbfx | |
tag: latest | |
fileName: ${{ env.ci_native_sdk_name }} | |
- name: Unzip native SDK | |
run: | | |
cd ${{ github.workspace }} | |
unzip ${{ env.ci_native_sdk_name }} | |
- name: Setup cmake | |
uses: jwlawson/[email protected] | |
with: | |
cmake-version: '${{ env.CMAKE_VERSION }}' | |
- name: Dependencies | |
shell: bash | |
run: ${{ env.ci_build_script }} dependencies | |
- name: Generate | |
shell: bash | |
run: ${{ env.ci_build_script }} generate | |
- name: Build | |
shell: bash | |
run: ${{ env.ci_build_script }} build | |
- name: Prepare | |
shell: bash | |
run: ${{ env.ci_build_script }} prepare | |
- name: Publish | |
if: ${{ github.ref == 'refs/heads/master' && github.repository == 'rbfx/sample-project' }} | |
uses: KikimoraGames/[email protected] | |
with: | |
butlerApiKey: ${{ secrets.BUTLER_API_KEY }} | |
gameData: ${{ github.workspace }}/cmake-build/bin/project | |
itchUsername: eugeneko | |
itchGameId: sample-project | |
buildChannel: web |