transpile.yml 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. name: Transpile
  2. on:
  3. workflow_dispatch: {}
  4. push:
  5. branches: [patched/*]
  6. concurrency:
  7. group: transpile-${{ github.ref_name }}
  8. cancel-in-progress: true
  9. jobs:
  10. transpile:
  11. runs-on: ubuntu-latest
  12. if: startsWith(github.ref, 'refs/heads/patched/')
  13. steps:
  14. - run: echo ::set-output name=name::"${GITHUB_REF#refs/heads/patched/}"
  15. id: branch
  16. - uses: actions/checkout@v2
  17. with:
  18. fetch-depth: 0
  19. ssh-key: ${{ secrets.DEPLOY_KEY }}
  20. - uses: actions/setup-node@v1
  21. with:
  22. node-version: 12.x
  23. - uses: actions/cache@v2
  24. id: cache
  25. with:
  26. path: '**/node_modules'
  27. key: npm-v2-${{ hashFiles('**/package-lock.json') }}
  28. restore-keys: npm-v2-
  29. - run: npm ci
  30. if: steps.cache.outputs.cache-hit != 'true'
  31. - run: bash scripts/upgradeable/git-user-config.sh
  32. - run: bash scripts/upgradeable/transpile-onto.sh ${{ steps.branch.outputs.name }} origin/${{ steps.branch.outputs.name }}
  33. - run: git push origin ${{ steps.branch.outputs.name }}