-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #777 from willowtreeapps/task/732-migrate-to-githu…
…bactions [732] - Migrate to GitHub Actions
- Loading branch information
Showing
69 changed files
with
363 additions
and
233,939 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
name: Run Lane | ||
description: Run a fastane lane and upload artifacts | ||
inputs: | ||
lane: | ||
description: Name of fastlane lane to run | ||
required: true | ||
match_password: | ||
description: Match password, ideally in secrets.MATCH_PASSWORD | ||
required: false | ||
runs: | ||
using: composite | ||
steps: | ||
- name: Run fastlane | ||
run: bundle exec fastlane ${{ inputs.lane }} | ||
shell: sh | ||
env: | ||
MATCH_PASSWORD: ${{ inputs.match_password }} | ||
|
||
# TODO: Artifacts |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
name: Pull Translations From Crowdin | ||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: "0 */3 * * *" # Run every 3 hours | ||
|
||
jobs: | ||
synchronize-with-crowdin: | ||
runs-on: macos-14 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Crowdin CLI | ||
run: brew install crowdin | ||
shell: sh | ||
|
||
- name: Download Translations | ||
run: crowdin bundle download 6 | ||
shell: sh | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.CROWDIN_GITHUB_TOKEN }} | ||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} | ||
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} | ||
|
||
- name: Set up Ruby environment | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: 3.0 | ||
|
||
- name: Install bundler | ||
run: gem install bundler | ||
|
||
- name: Install dependencies | ||
run: bundle install | ||
|
||
- name: Install SwiftLint | ||
run: brew install swiftlint | ||
|
||
- name: Import XLIFFs to project | ||
uses: ./.github/workflows/actions/run_lane | ||
with: | ||
lane: xliff_import | ||
|
||
- name: Create Pull Request | ||
uses: peter-evans/create-pull-request@v6 | ||
with: | ||
token: ${{ secrets.CROWDIN_PR_BOT_TOKEN }} | ||
commit-message: Update Localizations | ||
committer: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> | ||
author: ${{ github.actor }} <${{ github.actor_id }}+${{ github.actor }}@users.noreply.github.com> | ||
signoff: false | ||
branch: crowdin/update-translations-bot | ||
base: develop | ||
delete-branch: true | ||
add-paths: | | ||
Vocable/**/*.xcstrings | ||
Vocable/**/*.strings | ||
title: '[CI] Update Localizations' | ||
body: | | ||
Automated localization update from Crowdin. | ||
labels: | | ||
localization | ||
automated | ||
draft: false |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Push Strings to Crowdin | ||
|
||
on: | ||
push: | ||
branches: [ develop ] | ||
workflow_dispatch: | ||
inputs: | ||
test: | ||
description: Just to force the manual trigger | ||
required: false | ||
default: 'trigger' | ||
jobs: | ||
synchronize-with-crowdin: | ||
runs-on: macos-14 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install Crowdin CLI | ||
run: brew install crowdin | ||
shell: sh | ||
|
||
- name: Upload Sources | ||
run: > | ||
crowdin upload sources | ||
shell: sh | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.CROWDIN_GITHUB_TOKEN }} | ||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }} | ||
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
name: On pull request | ||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
branches: | ||
- develop | ||
|
||
jobs: | ||
on_pull_request: | ||
runs-on: macos-14 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Install SSH key | ||
uses: shimataro/ssh-key-action@v2 | ||
with: | ||
key: ${{ secrets.FASTLANE_MATCH_GIT_PRIVATE_KEY }} | ||
known_hosts: ${{ secrets.MATCH_SSH_KNOWN_HOSTS }} | ||
name: id_rsa_match | ||
|
||
- name: Set up Ruby environment | ||
uses: ruby/setup-ruby@v1 | ||
with: | ||
ruby-version: 3.0 | ||
|
||
- name: Install bundler | ||
run: gem install bundler | ||
|
||
- name: Install dependencies | ||
run: bundle install | ||
|
||
- name: Install SwiftLint | ||
run: brew install swiftlint | ||
|
||
- name: Run Unit and UI tests | ||
uses: ./.github/workflows/actions/run_lane | ||
with: | ||
lane: test_unit_ui | ||
match_password: ${{ secrets.MATCH_PASSWORD }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
name: On release push | ||
on: | ||
push: | ||
branches: | ||
- release.** | ||
jobs: | ||
on_release_push: | ||
runs-on: macos-14 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Run Unit and UI tests | ||
uses: ./.github/workflows/actions/run_lane | ||
with: | ||
lane: test_unit_ui | ||
match_password: ${{ secrets.MATCH_PASSWORD }} | ||
|
||
- name: Commit translation file if changed | ||
uses: ./.github/workflows/actions/xliff_export | ||
|
||
- name: Build and deploy to TestFlight | ||
uses: ./.github/workflows/actions/run_lane | ||
with: | ||
lane: build_deploy_testflight | ||
match_password: ${{ secrets.MATCH_PASSWORD }} |
Oops, something went wrong.