Skip to content

add checkout v3

add checkout v3 #121

Workflow file for this run

name: Translate and Test
on:
pull_request:
paths:
- "extension/**/*"
jobs:
# test-ci:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v2
# - uses: actions/setup-node@v2
# with:
# node-version: 16.14.0
# - run: yarn install
# - run: yarn build:freighter-api
# - run: yarn test:ci
build-translations:
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false
fetch-depth: 0
- uses: actions/setup-node@v1
with:
node-version: "16.14.0"
- name: Run translation job
run: |
yarn && yarn build:freighter-api && yarn build:extension:translations
- name: Verify diff
id: verify_diff
run: |
git diff --quiet || echo "::set-output name=new_translations_exist::true"
- name: Commit files
if: steps.verify_diff.outputs.new_translations_exist == 'true'
uses: actions/checkout@v3
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git commit -m "Add translations" -a
git push origin HEAD:${{ github.head_ref }}
# - name: Push changes
# if: steps.verify_diff.outputs.new_translations_exist == 'true'
# uses: ad-m/github-push-action@master
# with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
# branch: ${{ github.head_ref }}
- name: Run tests
run: |
yarn test:ci