Skip to content

Commit 321adc8

Browse files
committed
feat: 支持迁移postgres及mysql数据库
1 parent 2cd06ac commit 321adc8

19 files changed

Lines changed: 993 additions & 22 deletions

File tree

.github/workflows/publish.yml

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
jobs:
2+
pipeline:
3+
name: publish
4+
runs-on: ubuntu-latest
5+
steps:
6+
- uses: actions/checkout@v4
7+
- name: Setup git
8+
run: |-
9+
git config --local user.email github_bot@users.noreply.github.com
10+
git config --local user.name GithubBot
11+
- name: Setup node
12+
uses: actions/setup-node@v3
13+
with:
14+
node-version: 22.16.0
15+
- name: Setup pnpm
16+
uses: pnpm/action-setup@v2
17+
with:
18+
version: 10.11.1
19+
- name: Setup pnpm cache
20+
uses: actions/cache@v3
21+
with:
22+
path: node_modules
23+
key: pnpm-cache-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}
24+
- name: Install deps
25+
env:
26+
HUSKY: 0
27+
SKIP_INSTALL_SIMPLE_GIT_HOOKS: 1
28+
SKIP_SIMPLE_GIT_HOOKS: 1
29+
run: pnpm install --frozen-lockfile
30+
- name: Bump version and push tag
31+
id: tag_version
32+
uses: mathieudutour/github-tag-action@v6.2
33+
with:
34+
github_token: ${{ secrets.GITHUB_TOKEN }}
35+
- name: Updated npm version and create commit
36+
run: |-
37+
npm pkg set version=${{ steps.tag_version.outputs.new_version }}
38+
git add -A
39+
git commit -m "chore: published tag ${{steps.tag_version.outputs.new_tag}}"
40+
- name: Run build
41+
env:
42+
NODE_ENV: production
43+
run: |
44+
pnpm build
45+
- name: Create a GitHub release
46+
uses: ncipollo/release-action@v1
47+
with:
48+
tag: ${{ steps.tag_version.outputs.new_tag }}
49+
name: Release ${{ steps.tag_version.outputs.new_tag }}
50+
body: ${{ steps.tag_version.outputs.changelog }}
51+
- name: Publish library to npm
52+
uses: JS-DevTools/npm-publish@v3
53+
with:
54+
token: ${{ secrets.NPM_AUTH_TOKEN }}
55+
- name: Push changes
56+
uses: ad-m/github-push-action@master
57+
with:
58+
github_token: ${{ secrets.GITHUB_TOKEN }}
59+
branch: ${{ github.ref }}
60+
name: publish
61+
on:
62+
push:
63+
branches:
64+
- master
65+
permissions:
66+
contents: write
67+
id-token: write

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,3 +172,6 @@ index.html.js
172172
index.html.vue
173173

174174
stats.html
175+
176+
migrations/
177+
.migrate.json

.migrate.json

Lines changed: 0 additions & 3 deletions
This file was deleted.

0 commit comments

Comments
 (0)