-
Notifications
You must be signed in to change notification settings - Fork 2
52 lines (44 loc) · 1.31 KB
/
css-check.yml
File metadata and controls
52 lines (44 loc) · 1.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: css-check
on:
pull_request:
branches: ['main', 'release/**']
types: [opened, synchronize]
paths: ['packages/**']
jobs:
avoid_redundancy:
runs-on: ubuntu-20.04
steps:
- name: Cancel previous runs ❌
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}
build:
runs-on: ubuntu-20.04
steps:
- name: Checkout 🔍
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup node ⚙️
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- name: Cache dependencies 📦
uses: actions/cache@v4
id: cache-node_modules
with:
path: 'node_modules'
key: ${{ runner.os }}-node_modules-${{ hashFiles('**/package-lock.json') }}-${{ hashFiles('.github/workflows/css-check.yml') }}
- name: Install dependencies ⬇️
if: steps.cache-node_modules.outputs.cache-hit != 'true'
run: |
npm install -g sass
npm install --workspace=packages
- name: Build Sass 🫶🏼
run: npm run build --workspace=packages
- name: Upload artifact 🆙
uses: actions/upload-artifact@v4
with:
name: dist
path: dist