Skip to content

Commit

Permalink
fix: change build scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
terwer committed Mar 14, 2024
1 parent 49688d9 commit 129a934
Show file tree
Hide file tree
Showing 18 changed files with 21 additions and 311 deletions.
File renamed without changes.
Expand Up @@ -30,8 +30,8 @@ jobs:
- name: Install dependencies
run: pnpm install

- name: Build
run: pnpm build
- name: Prepare release
run: pnpm prepareRelease

- name: Package
run: pnpm package
File renamed without changes.
8 changes: 0 additions & 8 deletions DEVELOPMENT.md
Expand Up @@ -23,14 +23,6 @@ pnpm dev -F picgo-plugin-bootstrap

## Build

build

```bash
pnpm build
```

package

```bash
pnpm package
```
Expand Down
8 changes: 6 additions & 2 deletions package.json
@@ -1,14 +1,18 @@
{
"name": "siyuan-plugin-picgo-workspace",
"version": "1.5.1",
"description": "picgo plugin for siyuan-note",
"scripts": {
"serve": "turbo run serve",
"dev": "turbo run dev",
"build": "turbo run build",
"lint": "turbo run lint",
"cz": "git-cz",
"makeLink": "python make_dev_link.py",
"package": "python package.py"
"makeLink": "python scripts/make_dev_link.py",
"syncVersion": "python scripts/version.py",
"parseChangelog": "python scripts/parse_changelog.py",
"prepareRelease": "pnpm syncVersion && pnpm parseChangelog",
"package": "python scripts/package.py"
},
"config": {
"commitizen": {
Expand Down
Empty file removed package.py
Empty file.
2 changes: 1 addition & 1 deletion packages/picgo-plugin-app/package.json
Expand Up @@ -25,4 +25,4 @@
"vue": "^3.4.21",
"zhi-lib-base": "^0.8.0"
}
}
}
6 changes: 1 addition & 5 deletions packages/picgo-plugin-app/scripts/build.py
Expand Up @@ -6,9 +6,5 @@
# Windows 必须添加此设置
sys.stdout.reconfigure(encoding="utf-8")

# siyuan-plugin-bootstrap
# os.system("")

# picgo-app
os.system("vue-tsc && vite build")
print"PicGO plugin build success")
print("PicGO plugin build success")
12 changes: 0 additions & 12 deletions packages/picgo-plugin-bootstrap/index.html

This file was deleted.

9 changes: 2 additions & 7 deletions packages/picgo-plugin-bootstrap/package.json
Expand Up @@ -8,15 +8,10 @@
"author": "terwer",
"license": "MIT",
"scripts": {
"serve": "vite",
"dev": "vite build --watch",
"build": "vite build",
"start": "vite preview",
"test": "vitest --watch",
"syncVersion": "python scripts/version.py",
"parseChangelog": "python scripts/parse_changelog.py",
"prepareRelease": "pnpm syncVersion && pnpm parseChangelog",
"package": "python scripts/package.py"
"test": "vitest --watch"
},
"devDependencies": {
"@sveltejs/vite-plugin-svelte": "^2.4.1",
Expand All @@ -42,4 +37,4 @@
"zhi-device": "^2.11.0",
"zhi-lib-base": "^0.2.4"
}
}
}
5 changes: 0 additions & 5 deletions packages/picgo-plugin-bootstrap/scripts/.gitignore

This file was deleted.

7 changes: 0 additions & 7 deletions packages/picgo-plugin-bootstrap/scripts/README.md

This file was deleted.

235 changes: 0 additions & 235 deletions packages/picgo-plugin-bootstrap/scripts/scriptutils.py

This file was deleted.

File renamed without changes.
Expand Up @@ -9,14 +9,17 @@
# 获取当前工作空间
cwd = scriptutils.get_workdir()

dist_folder = "./dist"
os.system("pnpm build -F picgo-plugin-app")
os.system("pnpm build -F picgo-plugin-bootstrap")

dist_folder = "./artifacts/siyuan-plugin-picgo/dist"
data = scriptutils.read_json_file(cwd + "package.json")
v = data["version"]

src_folder = dist_folder
tmp_folder_name = "./siyuan-plugin-demo"
tmp_folder_name = "./siyuan-plugin-picgo"
build_zip_path = "./build"
build_zip_name = "siyuan-plugin-demo-" + v + ".zip"
build_zip_name = "siyuan-plugin-picgo-" + v + ".zip"

try:
# 压缩dist为zip
Expand Down
File renamed without changes.
File renamed without changes.

0 comments on commit 129a934

Please sign in to comment.