Skip to content

split cards

split cards #4

Workflow file for this run

name: Build Components
on:
push:
branches:
- '**'
paths:
- '.github/workflows/build-js.yaml'
- 'src/*.js'
- 'src/**/*.js'
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: '16'
- name: Install dependencies
run: |
npm install terser -g
- name: Minify and merge JS files
run: |
npm run build
- name: Commit and push changes
run: |
git config user.name "GitHub Actions"
git config user.email "github-actions@github.com"
git add dist/ha-public-transport-connection-card.js
if [[ $(git status --porcelain=v1 | wc -l) -ne 0 ]]; then
git commit -m "Auto-minify and merge JS files"
git push
fi