Skip to content

Commit

Permalink
ci(header): adds actions to lint and build
Browse files Browse the repository at this point in the history
Signed-off-by: Kai Henseler <[email protected]>
  • Loading branch information
bromiesTM committed Jul 23, 2024
1 parent ed1da3f commit 167ac30
Show file tree
Hide file tree
Showing 2 changed files with 66 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/header-building.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Header Build and Create Pull Request

on:
push:
paths:
- 'IONOS/**'
- '!core/js/custom-elements/global-navigation/**'

jobs:
build-and-pr:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20

- name: Install dependencies
run: cd IONOS/ && npm ci

- name: Run build
run: cd IONOS/ && npm run build

- name: Create Pull Request
uses: peter-evans/create-pull-request@v6
with:
commit-message: "build(header): auto build header"
committer: github-actions[bot]
author: ${{ github.actor }} <${{ github.actor_id }}>
branch: header-build-output
delete-branch: true
signoff: true
title: "Automated Header build output"
body: "This PR was created automatically by GitHub Actions"
29 changes: 29 additions & 0 deletions .github/workflows/header-linting.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Header Code Quality

on:
push:
paths:
- 'IONOS/**'

jobs:
code-quality:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Install Node
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'npm'

- name: Install Dependencies
run: cd IONOS/ && npm ci

- name: Lint Headers
run: cd IONOS/ && npm run lint
continue-on-error: true

- name: Prettier
run: cd IONOS/ && npm run format:check
continue-on-error: true

0 comments on commit 167ac30

Please sign in to comment.