fix: Cache used MFA codes using hash of secret rather than secret and code #5484
Workflow file for this run
This file contains hidden or 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: translation-update | |
| on: | |
| pull_request: | |
| branches: | |
| - 4.x | |
| types: | |
| - closed | |
| permissions: | |
| contents: read | |
| jobs: | |
| translation-update: | |
| runs-on: ubuntu-latest | |
| if: github.event.pull_request.merged == true | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 | |
| with: | |
| fetch-depth: 0 | |
| persist-credentials: false | |
| - name: Detect English translation changes | |
| id: changed-files | |
| env: | |
| BASE_SHA: ${{ github.event.pull_request.base.sha }} | |
| MERGE_SHA: ${{ github.event.pull_request.merge_commit_sha }} | |
| run: | | |
| if git diff --name-only "${BASE_SHA}" "${MERGE_SHA}" | grep -qE '^packages/[^/]+/resources/lang/en/'; then | |
| echo "any_changed=true" >> "$GITHUB_OUTPUT" | |
| else | |
| echo "any_changed=false" >> "$GITHUB_OUTPUT" | |
| fi | |
| - name: Notify on Discord | |
| if: steps.changed-files.outputs.any_changed == 'true' | |
| env: | |
| DISCORD_WEBHOOK: ${{ secrets.TRANSLATION_BOT_DISCORD_WEBHOOK }} | |
| uses: Ilshidur/action-discord@d2594079a10f1d6739ee50a2471f0ca57418b554 # 0.4.0 | |
| with: | |
| args: '<@&1026513157142872185> PR [#${{ github.event.number }}](${{ github.server_url }}/${{ github.repository }}/pull/${{ github.event.number }}/files) introduced translation changes.' |