Skip to content

fix: compileTS workflow #378

fix: compileTS workflow

fix: compileTS workflow #378

Workflow file for this run

name: Compile TS
on: [pull_request]
permissions:
contents: write
pull-requests: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Checkout PR
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh pr checkout ${{ github.event.pull_request.number }}
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Compile TS
run: yarn build
- name: Setup Git
run: |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
- name: Check for changes
run: |
git add .
if git diff --cached --quiet; then
echo "No changes detected after build."
exit 0
fi
git commit -m "chore(dist): update compiled files"
- name: Push changes
run: git push --force-if-includes
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}