-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (51 loc) · 1.58 KB
/
build-sass.yml
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
53
54
55
56
57
58
59
60
61
62
63
name: "release-sass"
on:
push:
branches:
- dev
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout current branch
uses: actions/checkout@v4
- name: "Setup Node"
uses: actions/setup-node@v4
with:
node-version: 21
- name: "Install npm dependencies"
run: npm install
- name: "Building SASS files"
run: npm run sass
- name: Set up Git Config
run: |
git config user.email "[email protected]"
git config user.name "GitHub Actions"
- name: commit built sass
uses: actions-x/commit@v6
with:
email: [email protected]
name: Autocommiting Built CSS
files: ./dist/*
token: ${{ secrets.MY_SECRET_TOKEN }}
force: true
- name: version
id: version
run: |
echo version=$(npm run version --silent) >> "$GITHUB_OUTPUT"
- name: Tag version
id: tag_version
# if: github.ref == 'refs/heads/master'
uses: mathieudutour/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
custom_tag: ${{ steps.version.outputs.version }}
- name: Make Css zip
run: |
zip -r cssonly.zip ./dist/*.css
- uses: ncipollo/release-action@v1
with:
artifacts: "cssonly.zip"
skipIfReleaseExists: true
name: "CSS files ${{ steps.version.outputs.version }}"