codeowners #195
This file contains 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: Compile TypeScript | |
on: | |
push: | |
branches: | |
- main | |
- dev | |
jobs: | |
build: | |
permissions: | |
contents: write | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Install node | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- name: Compile | |
run: | | |
npm i -g typescript | |
tsc | |
- name: Commit | |
run: | | |
git config --global user.name 'github-actions[bot]' | |
git config --global user.email 'github-actions[bot]@users.noreply.github.com' | |
git add smiggins/static/js | |
git diff --cached --quiet || (git commit -m 'Compile TypeScript files to JavaScript' && git push) | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |