npm-website: bump webpack-dev-middleware from 5.3.3 to 5.3.4 in /webs… #435
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: CI - Push | |
'on': | |
push: | |
branches: | |
- main | |
jobs: | |
lint: | |
name: Run Linters | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out Git repository | |
uses: actions/checkout@v4 | |
- name: Setup Node.JS | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '16' | |
- name: Cache node modules | |
uses: actions/[email protected] | |
env: | |
cache-name: cache-node-modules | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: ~/.npm | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-build-${{ env.cache-name }}- | |
${{ runner.os }}-build- | |
${{ runner.os }}- | |
- name: Website - Install dependencies | |
run: cd website && npm ci | |
- id: yamllint | |
name: Yamllint | |
uses: reviewdog/action-yamllint@v1 | |
with: | |
github_token: ${{ secrets.github_token }} | |
reporter: github-check | |
yamllint_flags: '.' | |
fail_on_error: true | |
filter_mode: nofilter | |
- if: always() | |
id: eslint | |
name: ESLint | |
uses: reviewdog/[email protected] | |
with: | |
github_token: ${{ secrets.github_token }} | |
reporter: github-check | |
eslint_flags: --ext js,jsx . | |
fail_on_error: true | |
filter_mode: nofilter | |
workdir: website | |
prettier: | |
name: Prettier - Enforce code style | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out Git repository | |
uses: actions/checkout@v4 | |
- name: Setup Node.JS | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '16' | |
- name: Cache node modules | |
uses: actions/[email protected] | |
env: | |
cache-name: cache-node-modules | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: ~/.npm | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-build-${{ env.cache-name }}- | |
${{ runner.os }}-build- | |
${{ runner.os }}- | |
- name: Install dependencies | |
run: npm ci | |
- id: prettier | |
name: Prettier | |
uses: creyD/[email protected] | |
with: | |
dry: true | |
prettier_options: --write . | |
env: | |
GITHUB_TOKEN: ${{ secrets.github_token }} | |
gh-pages: | |
name: Deploy to GH Pages | |
needs: | |
- lint | |
- prettier | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out Git repository | |
uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.head_ref }} | |
- name: Setup Node.JS | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '16' | |
- name: Cache node modules | |
uses: actions/[email protected] | |
env: | |
cache-name: cache-node-modules | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: ~/.npm | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-build-${{ env.cache-name }}- | |
${{ runner.os }}-build- | |
${{ runner.os }}- | |
- name: Install dependencies | |
run: npm ci | |
- name: Website - Install dependencies | |
run: cd website && npm ci | |
- name: Website - Build | |
run: cd website && npm run build | |
- name: Create .nojekyll file | |
run: touch website/build/.nojekyll | |
- name: Deploy to GitHub Pages | |
uses: s0/[email protected] | |
env: | |
REPO: self | |
BRANCH: gh-pages | |
FOLDER: website/build | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
MESSAGE: '🤖 Deploy static site for change: {msg}' | |
SKIP_EMPTY_COMMITS: true |