Skip to content

Create SimpleProgram.js #19

Create SimpleProgram.js

Create SimpleProgram.js #19

Workflow file for this run

name: Build and Process JSON
on:
push:
branches:
- main
paths:
- '**.js'
- '**.ts'
- '**.module.json'
pull_request:
branches:
- main
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: 'latest'
- name: Install dependencies and transpile TypeScript
run: cd compiler && npm install && npx tsc --noCheck && cd ..
- name: Find and process *.module.json files
run: |
find . -name '*.module.json' | while read path; do
node compiler/dist/cli ?json "$path"
done
- name: Commit generated code
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git config user.name "GitHub Actions Bot"
git config user.email "<>"
git add -A
git diff --quiet && git diff --staged --quiet || git commit -m "Generated code"
git pull --rebase
- name: Push changes
uses: ad-m/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}