Bumps the actions group with 6 updates: | Package | From | To | | --- | --- | --- | | [actions/checkout](https://github.com/actions/checkout) | `3` | `4` | | [actions/cache](https://github.com/actions/cache) | `3` | `4` | | [peter-evans/repository-dispatch](https://github.com/peter-evans/repository-dispatch) | `2` | `3` | | [actions/download-artifact](https://github.com/actions/download-artifact) | `3` | `4` | | [Apple-Actions/import-codesign-certs](https://github.com/apple-actions/import-codesign-certs) | `2` | `3` | | [softprops/action-gh-release](https://github.com/softprops/action-gh-release) | `0.1.15` | `2.0.5` | Updates `actions/checkout` from 3 to 4 - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3...v4) Updates `actions/cache` from 3 to 4 - [Release notes](https://github.com/actions/cache/releases) - [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md) - [Commits](https://github.com/actions/cache/compare/v3...v4) Updates `peter-evans/repository-dispatch` from 2 to 3 - [Release notes](https://github.com/peter-evans/repository-dispatch/releases) - [Commits](https://github.com/peter-evans/repository-dispatch/compare/v2...v3) Updates `actions/download-artifact` from 3 to 4 - [Release notes](https://github.com/actions/download-artifact/releases) - [Commits](https://github.com/actions/download-artifact/compare/v3...v4) Updates `Apple-Actions/import-codesign-certs` from 2 to 3 - [Release notes](https://github.com/apple-actions/import-codesign-certs/releases) - [Commits](https://github.com/apple-actions/import-codesign-certs/compare/v2...v3) Updates `softprops/action-gh-release` from 0.1.15 to 2.0.5 - [Release notes](https://github.com/softprops/action-gh-release/releases) - [Changelog](https://github.com/softprops/action-gh-release/blob/master/CHANGELOG.md) - [Commits](https://github.com/softprops/action-gh-release/compare/v0.1.15...v2.0.5) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major dependency-group: actions - dependency-name: actions/cache dependency-type: direct:production update-type: version-update:semver-major dependency-group: actions - dependency-name: peter-evans/repository-dispatch dependency-type: direct:production update-type: version-update:semver-major dependency-group: actions - dependency-name: actions/download-artifact dependency-type: direct:production update-type: version-update:semver-major dependency-group: actions - dependency-name: Apple-Actions/import-codesign-certs dependency-type: direct:production update-type: version-update:semver-major dependency-group: actions - dependency-name: softprops/action-gh-release dependency-type: direct:production update-type: version-update:semver-major dependency-group: actions ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
216 lines
5.7 KiB
YAML
216 lines
5.7 KiB
YAML
name: Release
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
ref:
|
|
description: 'Ref to build (for Pull Requests, use refs/pull/NNN/head)'
|
|
required: true
|
|
repository_dispatch:
|
|
# client_payload should be the same as the inputs for workflow_dispatch.
|
|
types:
|
|
- Build*
|
|
release:
|
|
types:
|
|
- published
|
|
|
|
jobs:
|
|
source:
|
|
name: Source
|
|
|
|
uses: ./.github/workflows/release-source.yml
|
|
secrets: inherit
|
|
|
|
docs:
|
|
name: Docs
|
|
needs: source
|
|
if: ${{ false }} # CM
|
|
|
|
uses: ./.github/workflows/release-docs.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
version: ${{ needs.source.outputs.version }}
|
|
|
|
linux:
|
|
name: Linux (Generic)
|
|
needs: source
|
|
|
|
uses: ./.github/workflows/release-linux.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
survey_key: ${{ needs.source.outputs.survey_key }}
|
|
|
|
macos:
|
|
name: MacOS
|
|
needs: source
|
|
|
|
uses: ./.github/workflows/release-macos.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
survey_key: ${{ needs.source.outputs.survey_key }}
|
|
|
|
windows:
|
|
name: Windows
|
|
needs: source
|
|
|
|
uses: ./.github/workflows/release-windows.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
is_tag: ${{ needs.source.outputs.is_tag }}
|
|
survey_key: ${{ needs.source.outputs.survey_key }}
|
|
|
|
windows-store:
|
|
name: Windows Store
|
|
needs:
|
|
- source
|
|
- windows
|
|
|
|
if: ${{ false }} # CM
|
|
# if: needs.source.outputs.is_tag == 'true'
|
|
|
|
uses: ./.github/workflows/release-windows-store.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
version: ${{ needs.source.outputs.version }}
|
|
|
|
upload:
|
|
name: Upload
|
|
needs:
|
|
- source
|
|
- docs
|
|
- linux
|
|
- macos
|
|
- windows
|
|
- windows-store
|
|
|
|
if: ${{ false }} # CM
|
|
# As windows-store is condition, we need to check ourselves if we need to run.
|
|
# The always() makes sure the rest is always evaluated.
|
|
# if: always() && needs.source.result == 'success' && needs.docs.result == 'success' && needs.linux.result == 'success' && needs.macos.result == 'success' && needs.windows.result == 'success' && (needs.windows-store.result == 'success' || needs.windows-store.result == 'skipped')
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
# This job is empty, but ensures no upload job starts before all targets finished and are successful.
|
|
steps:
|
|
- name: Build completed
|
|
run: |
|
|
true
|
|
|
|
upload-cdn:
|
|
name: Upload (CDN)
|
|
needs:
|
|
- source
|
|
- upload
|
|
|
|
# As windows-store is condition, we need to check ourselves if we need to run.
|
|
# The always() makes sure the rest is always evaluated.
|
|
# Yes, you even need to do this if you yourself don't depend on the condition.
|
|
if: always() && needs.source.result == 'success' && needs.upload.result == 'success'
|
|
|
|
uses: ./.github/workflows/upload-cdn.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
version: ${{ needs.source.outputs.version }}
|
|
folder: ${{ needs.source.outputs.folder }}
|
|
trigger_type: ${{ needs.source.outputs.trigger_type }}
|
|
|
|
upload-steam:
|
|
name: Upload (Steam)
|
|
needs:
|
|
- source
|
|
- upload
|
|
|
|
# As windows-store is condition, we need to check ourselves if we need to run.
|
|
# The always() makes sure the rest is always evaluated.
|
|
# Yes, you even need to do this if you yourself don't depend on the condition.
|
|
# Additionally, only nightlies and releases go to Steam; not PRs.
|
|
# if: always() && needs.source.result == 'success' && needs.upload.result == 'success' && (needs.source.outputs.trigger_type == 'new-master' || needs.source.outputs.trigger_type == 'new-tag')
|
|
if: ${{ false }} # CM
|
|
|
|
uses: ./.github/workflows/upload-steam.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
version: ${{ needs.source.outputs.version }}
|
|
trigger_type: ${{ needs.source.outputs.trigger_type }}
|
|
|
|
upload-gog:
|
|
name: Upload (GOG)
|
|
needs:
|
|
- source
|
|
- upload
|
|
|
|
# As windows-store is condition, we need to check ourselves if we need to run.
|
|
# The always() makes sure the rest is always evaluated.
|
|
# Yes, you even need to do this if you yourself don't depend on the condition.
|
|
# Additionally, only releases go to GOG; not nightlies or PRs.
|
|
# if: always() && needs.source.result == 'success' && needs.upload.result == 'success' && needs.source.outputs.trigger_type == 'new-tag'
|
|
if: ${{ false }} # CM
|
|
|
|
uses: ./.github/workflows/upload-gog.yml
|
|
secrets: inherit
|
|
|
|
with:
|
|
version: ${{ needs.source.outputs.version }}
|
|
|
|
cm-upload-github:
|
|
name: Release GitHub assets
|
|
needs:
|
|
- source
|
|
- linux
|
|
- macos
|
|
- windows
|
|
|
|
if: needs.source.outputs.trigger_type == 'new-master' || needs.source.outputs.trigger_type == 'new-tag'
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
steps:
|
|
- name: Download all bundles
|
|
uses: actions/download-artifact@v4
|
|
|
|
- name: Release GitHub assets
|
|
uses: softprops/action-gh-release@v2.0.5
|
|
|
|
# if: startsWith(github.ref, 'refs/tags/')
|
|
with:
|
|
files: |
|
|
citymania-client-*/*.zip
|
|
citymania-client-*/*.xz
|
|
citymania-client-*/*.dmg
|
|
|
|
cm-upload-citymania:
|
|
name: Upload to CityMania
|
|
needs:
|
|
- source
|
|
- linux
|
|
- macos
|
|
- windows
|
|
|
|
# if: ${{ false }}
|
|
if: needs.source.outputs.trigger_type == 'new-master' || needs.source.outputs.trigger_type == 'new-tag'
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
steps:
|
|
- name: Download all bundles
|
|
uses: actions/download-artifact@v4
|
|
|
|
- name: Upload to CityMania
|
|
uses: appleboy/scp-action@master
|
|
# if: startsWith(github.ref, 'refs/tags/')
|
|
with:
|
|
host: ${{ secrets.UPLOAD_HOST }}
|
|
username: ${{ secrets.UPLOAD_USERNAME }}
|
|
key: ${{ secrets.UPLOAD_KEY }}
|
|
port: ${{ secrets.UPLOAD_PORT }}
|
|
source: "citymania-client-*/*.zip,citymania-client-*/*.xz,citymania-client-*/*.dmg"
|
|
strip_components: 1
|
|
target: ${{ secrets.UPLOAD_PATH }}
|