-
Notifications
You must be signed in to change notification settings - Fork 1
51 lines (48 loc) · 1.28 KB
/
create-dev-build.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
name: DevBuild
on:
push:
branches: [ master ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
permissions:
actions: write
checks: write
contents: write
deployments: write
issues: write
packages: write
pull-requests: write
repository-projects: write
security-events: write
statuses: write
steps:
- uses: actions/checkout@v3
- name: setup Node
uses: actions/setup-node@v3
with:
node-version: 18.x
registry-url: 'https://registry.npmjs.org'
- name: init
run: |
npm i -g pnpm
pnpm install
- name: update .gitignore
run: sed -i -e '/\/dist/d' .gitignore
- name: generate dev build
run: pnpm build
- name: setup sandbox
run: |
cp ./dist/bundle.js ./docs/niwango-live-loader.user.js
cp ./package.json ./docs/package.json
- name: Create new Branch
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
git config user.email "[email protected]"
git config user.name "github-actions"
git checkout -b dev-build
git add .
git commit -m "auto generate" -n
git push -f origin dev-build