Skip to content

Merge pull request #138 from TwidereProject/develop #210

Merge pull request #138 from TwidereProject/develop

Merge pull request #138 from TwidereProject/develop #210

Workflow file for this run

name: Build and Release
on: push
# macOS environments: https://github.com/actions/virtual-environments/tree/main/images/macos
jobs:
build:
name: Release
runs-on: macos-12
if: contains(github.event.head_commit.message, '@r2d2/release')
steps:
- name: checkout
uses: actions/checkout@v2
# https://docs.github.com/en/[email protected]/actions/deployment/deploying-xcode-applications/installing-an-apple-certificate-on-macos-runners-for-xcode-development
- name: Import Code-Signing Certificates
uses: Apple-Actions/import-codesign-certs@v1 # https://github.com/Apple-Actions/import-codesign-certs
with:
p12-file-base64: ${{ secrets.CERTIFICATES_P12 }}
p12-password: ${{ secrets.CERTIFICATES_P12_PASSWORD }}
- name: Download Provisioning Profiles
uses: Apple-Actions/download-provisioning-profiles@v1 # https://github.com/Apple-Actions/download-provisioning-profiles
with:
bundle-id: com.twidere.TwidereX
issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
api-key-id: ${{ secrets.APPSTORE_KEY_ID }}
api-private-key: ${{ secrets.APPSTORE_PRIVATE_KEY }}
- name: setup
env:
AppSecret: ${{ secrets.AppSecret }}
HostKeyPublic: ${{ secrets.HostKeyPublic }}
ConsumerKeyDebug: ${{ secrets.ConsumerKeyDebug }}
ConsumerKeyRelease: ${{ secrets.ConsumerKeyRelease }}
ConsumerKeySecretDebug: ${{ secrets.ConsumerKeySecretDebug }}
ConsumerKeySecretRelease: ${{ secrets.ConsumerKeySecretRelease }}
OauthEndpointDebug: ${{ secrets.OauthEndpointDebug }}
OauthEndpointRelease: ${{ secrets.OauthEndpointRelease }}
ClientIDDebug: ${{ secrets.ClientIDDebug }}
ClientIDRelease: ${{ secrets.ClientIDRelease }}
ClientSecretDebug: ${{ secrets.ClientSecretDebug }}
ClientSecretRelease: ${{ secrets.ClientSecretRelease }}
Oauth2EndpointDebug: ${{ secrets.Oauth2EndpointDebug }}
Oauth2EndpointRelease: ${{ secrets.Oauth2EndpointRelease }}
MastodonNotificationEndpointDebug: ${{ secrets.MastodonNotificationEndpointDebug }}
MastodonNotificationEndpointRelease: ${{ secrets.MastodonNotificationEndpointRelease }}
run: exec ./.github/scripts/setup.sh
- name: build
run: exec ./.github/scripts/build-release.sh
- name: Upload TestFlight Build
uses: Apple-Actions/upload-testflight-build@master # https://github.com/Apple-Actions/upload-testflight-build
with:
app-path: .build/Artifacts/TwidereX.ipa/TwidereX.ipa
issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
api-key-id: ${{ secrets.APPSTORE_KEY_ID }}
api-private-key: ${{ secrets.APPSTORE_PRIVATE_KEY }}