mirror of
https://github.com/sern-handler/awesome-plugins
synced 2026-06-06 01:16:51 +00:00
45 lines
1.1 KiB
YAML
45 lines
1.1 KiB
YAML
name: Continuous Integration
|
|
|
|
on:
|
|
# Trigger the workflow on push or pull request,
|
|
# but only for the main branch
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request_target:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
Automation:
|
|
name: Run Automations
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Check out Git repository
|
|
uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # tag=v3
|
|
|
|
- name: Set up Node.js
|
|
uses: actions/setup-node@2fddd8803e2f5c9604345a0b591c3020ee971a93 # tag=v3
|
|
with:
|
|
node-version: 17
|
|
|
|
# Prettier must be in `package.json`
|
|
- name: Install Node.js dependencies
|
|
run: npm i -g prettier && npm i
|
|
|
|
- name: Run Prettier
|
|
run: prettier --check .
|
|
|
|
- name: Convert TypeScript to JavaScript
|
|
run: npx babel TypeScript --out-dir JavaScript --extensions ".ts"
|
|
|
|
- name: Run JavaScript Prettier
|
|
run: prettier --write ./JavaScript
|
|
|
|
- name: Commit changes
|
|
uses: stefanzweifel/git-auto-commit-action@v4
|
|
with:
|
|
commit-message: "chore: generated JavaScript plugins"
|
|
branch: js
|
|
create_branch: true |