Skip to content

Commit

Permalink
build: Fix github action
Browse files Browse the repository at this point in the history
  • Loading branch information
vio committed Feb 26, 2024
1 parent cae7228 commit 4237417
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 194 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/node.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: build

on:
push:
branches:
- main
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

# Cache packages when the branch is not update-dependencies or dependabot/*
- name: Resolve caching
id: cache
if: ${{ github.ref_name != 'update-dependencies' && !startsWith(github.ref_name, 'dependabot/') }}
run: echo "PACKAGE=npm" >> $GITHUB_OUTPUT

- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: ${{ steps.cache.outputs.PACKAGE }}

# Install dependencies
- run: npm ci

# Build and output webpack stats to artifacts/webpack-stats.json
- run: npm run build
working-directory: app

- name: Archive production artifacts
uses: actions/upload-artifact@v2
with:
name: test-artifacts
path: |
artifacts/webpack-stats.json
97 changes: 0 additions & 97 deletions app/.github/workflows/node.yaml

This file was deleted.

97 changes: 0 additions & 97 deletions components/.github/workflows/node.yaml

This file was deleted.

0 comments on commit 4237417

Please sign in to comment.