Skip to content

Feat/2271 blacklisted banner #1116

Feat/2271 blacklisted banner

Feat/2271 blacklisted banner #1116

name: Lingui extract - Storage
on:
pull_request:
branches:
- "dev"
paths:
- "packages/storage-ui/**/*"
jobs:
# extract any new translatable string
# and commit if there are new ones
# and if the user submitting the PR isn't weblate
extract:
name: lingui-extract
runs-on: ubuntu-latest
if: ${{ github.actor != 'weblate' }}
steps:
- uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.ref }}
ssh-key: ${{ secrets.LINGUI_GH_ACTION_COMMIT_KEY }}
- name: set user
run: |
git config --global user.name 'GitHub Actions'
git config --global user.email '[email protected]'
# use node module caching
- uses: actions/cache@v2
with:
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }}
- name: install packages
run: yarn install --immutable
- name: lingui-extract and commit
if: ${{ github.actor != 'weblate' }}
run: |
(cd packages/storage-ui && yarn extract --clean)
git add packages/storage-ui/src/locales/*
if git commit -m "lingui extract"; then git push; else echo 'exiting successfully without commit'; fi