-
-
Notifications
You must be signed in to change notification settings - Fork 146
48 lines (40 loc) · 1.04 KB
/
on_push_deploy.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
name: Build and Publish Plugins and Themes
on:
push:
branches:
- main
paths:
- .github/workflows/**
- plugins/**
- themes/**
- build-config.json
- build.js
- package.json
- yarn.lock
permissions:
contents: write
jobs:
build_and_publish:
name: Build and Publish Plugins and Themes
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: "0"
- name: Install node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: Install repository dependencies
run: yarn install --frozen-lockfile
- name: Build plugins and themes
run: yarn run build-all-dist
- name: Publish to stable branch
uses: s0/git-publish-subdir-action@develop
env:
REPO: self
BRANCH: stable
FOLDER: "dist" # build-config.json outDir
MESSAGE: "built for {sha}"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}