1
0
mirror of synced 2026-01-06 06:02:35 -05:00

Remove crowdin.yml workflow (#23490)

* Remove crowdin.yml workflow

Closes https://github.com/github/docs-engineering/issues/1341

* Fix test

Co-authored-by: Francis <15894826+francisfuzz@users.noreply.github.com>
This commit is contained in:
Marcelo Jacobus
2021-12-13 14:30:07 -03:00
committed by GitHub
parent 815f9d40c3
commit 26d7681b95
2 changed files with 0 additions and 91 deletions

View File

@@ -13,7 +13,6 @@ export default [
'actions/upload-artifact@27121b0bdffd731efa15d66772be8dc71245d074', // v2.2.4
'alex-page/github-project-automation-plus@bb266ff4dde9242060e2d5418e120a133586d488', // v0.8.1
'andymckay/labeler@e6c4322d0397f3240f0e7e30a33b5c5df2d39e90', // v1.0.4
'crowdin/github-action@d0622816ed4f4744db27d04374b2cef6867f7bed', // v1.4.1
'cschleiden/actions-linter@caffd707beda4fc6083926a3dff48444bc7c24aa', // uses github-actions-parser v0.23.0
'dawidd6/action-delete-branch@47743101a121ad657031e6704086271ca81b1911', // v3.0.2
'dawidd6/action-download-artifact@af92a8455a59214b7b932932f2662fdefbd78126', // v2.15.0

View File

@@ -1,90 +0,0 @@
name: Crowdin Sync
# **What it does**:
# **Why we have it**:
# **Who does it impact**: Docs localization.
on:
workflow_dispatch:
schedule:
- cron: '33 2 * * *' # every day at 2:33 UTC at least until automerge is working
jobs:
sync_with_crowdin:
name: Sync with Crowdin
if: github.repository == 'github/docs-internal'
runs-on: ubuntu-latest
# A sync's average run time is ~3.2 hours.
# This sets a maximum execution time of 300 minutes (5 hours) to prevent the workflow from running longer than necessary.
timeout-minutes: 300
steps:
- name: Checkout
uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579
with:
fetch-depth: 0
lfs: true
- name: Remove unwanted git hooks
run: rm .git/hooks/post-checkout
- name: Remove all translations
run: |
git rm -rf --quiet translations/*/content
git rm -rf --quiet translations/*/data
- name: Sync
uses: crowdin/github-action@d0622816ed4f4744db27d04374b2cef6867f7bed
with:
# This option enables the transfer of existing translations in this project to Crowdin.
# We explicitly set this to `false` since we only want to use the downloaded translations managed by Crowdin.
upload_translations: false
download_translations: true
create_pull_request: true
# Using a custom config temporarily to avoid clobbering the existing crowdin.yml
# that is used by the github-help-docs OAuth integration.
config: 'crowdin.yml'
# This is the name of the git branch that Crowdin will create when opening a pull request.
# This branch does NOT need to be manually created. It will be created automatically by the action.
localization_branch_name: translations
# This is the name of the top-level directory that Crowdin will use for files.
# Note that this is not a "branch" in the git sense, but more like a top-level directory in your Crowdin project.
# This branch does NOT need to be manually created. It will be created automatically by the action.
crowdin_branch_name: main
env:
# Using an @octoglot token instead of the default Actions-provided GITHUB_TOKEN here
# so that subsequent workflows will be able to run on the pull request created by this workflow.
GITHUB_TOKEN: ${{ secrets.OCTOGLOT_PAT_WITH_REPO_AND_WORKFLOW_SCOPE }}
# This is a numeric id, not to be confused with Crowdin API v1 "project identifier" string
# See "API v2" on https://crowdin.com/project/<your-project>/settings#api
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
# A personal access token, not to be confused with Crowdin API v1 "API key"
# See https://crowdin.com/settings#api-key to generate a token
# This token was created by logging into Crowdin with the octoglot user
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}
# When the maximum execution time is reached for this job, Actions cancels the workflow run.
# This emits a notification for the first responder to triage.
- name: Send Slack notification if workflow is cancelled
uses: someimportantcompany/github-actions-slack-message@f8d28715e7b8a4717047d23f48c39827cacad340
if: cancelled()
with:
channel: ${{ secrets.DOCS_ALERTS_SLACK_CHANNEL_ID }}
bot-token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }}
color: failure
text: The last Crowdin Sync run for ${{github.repository}} was cancelled. Please try running the workflow manually; see https://github.com/${{github.repository}}/actions/workflows/crowdin.yml
# Emit a notification for the first responder to triage if the workflow failed.
- name: Send Slack notification if workflow failed
uses: someimportantcompany/github-actions-slack-message@f8d28715e7b8a4717047d23f48c39827cacad340
if: failure()
with:
channel: ${{ secrets.DOCS_ALERTS_SLACK_CHANNEL_ID }}
bot-token: ${{ secrets.SLACK_DOCS_BOT_TOKEN }}
color: failure
text: The last Crowdin Sync run for ${{github.repository}} failed. See https://github.com/${{github.repository}}/actions/workflows/crowdin.yml