Quellcode durchsuchen

Merge dev into prod (keep prod config files)

liujia vor 2 Monaten
Ursprung
Commit
e0599d5a27
5 geänderte Dateien mit 866 neuen und 3 gelöschten Zeilen
  1. 9 0
      .gitmessage.txt
  2. 173 0
      CHANGELOG.md
  3. 7 3
      package.json
  4. 633 0
      pnpm-lock.yaml
  5. 44 0
      scripts/release.js

+ 9 - 0
.gitmessage.txt

@@ -0,0 +1,9 @@
+feat: 
+# feat: 新功能
+# fix: 修复 Bug
+# docs: 文档修改
+# style: 代码格式调整(不影响功能)
+# refactor: 重构(非新功能,非修 Bug)
+# perf: 性能优化
+# test: 测试相关
+# chore: 构建流程、依赖管理

+ 173 - 0
CHANGELOG.md

@@ -0,0 +1,173 @@
+## [0.1.20](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.19...v0.1.20) (2025-08-13)
+
+
+### Features
+
+* 更新部署脚本,调整版本号升级顺序 ([f126757](http://43.137.10.199:3000/liujia/ln-web/commits/f126757a623c8975d91ae5656d6e0a82ba600740))
+
+
+
+## [0.1.19](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.18...v0.1.19) (2025-08-13)
+
+
+
+## [0.1.18](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.17...v0.1.18) (2025-08-13)
+
+
+### Bug Fixes
+
+* :construction: release ([938b3d6](http://43.137.10.199:3000/liujia/ln-web/commits/938b3d6133df08c064665df587f6143d704a6ae7))
+
+
+
+## [0.1.17](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.16...v0.1.17) (2025-08-13)
+
+
+### Features
+
+* 更新release.js ([3d2b216](http://43.137.10.199:3000/liujia/ln-web/commits/3d2b21613980f81571706dbc7f19d58332a5b23c))
+
+
+
+## [0.1.16](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.15...v0.1.16) (2025-08-13)
+
+
+### Features
+
+* 更新发布脚本 ([704acd3](http://43.137.10.199:3000/liujia/ln-web/commits/704acd3b2124096bb28fa6bf4c9674686ca85966))
+* 更新发布脚本 ([bd26b27](http://43.137.10.199:3000/liujia/ln-web/commits/bd26b270ac2ccc626de9c18b5364ae5dde1e5696))
+* **scripts:** 测试日志生成 ([375e86d](http://43.137.10.199:3000/liujia/ln-web/commits/375e86d8da97e19e740c876e8421f584f381540f))
+
+
+
+## [0.1.15](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.14...v0.1.15) (2025-08-13)
+
+
+
+## [0.1.14](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.13...v0.1.14) (2025-08-13)
+
+
+### Features
+
+* **scripts:** 增强发布脚本功能并优化代码 ([adbef79](http://43.137.10.199:3000/liujia/ln-web/commits/adbef799124861306a6ff54b20ea20ea2985b413))
+
+
+
+## [0.1.13](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.12...v0.1.13) (2025-08-13)
+
+
+### Features
+
+* 添加发布脚本并优化发布流程 ([b8dffd2](http://43.137.10.199:3000/liujia/ln-web/commits/b8dffd2ab55e35afe641ed8dbe5755e4d67def30))
+
+
+
+## [0.1.12](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.11...v0.1.12) (2025-08-13)
+
+
+
+## [0.1.11](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.10...v0.1.11) (2025-08-13)
+
+
+### Bug Fixes
+
+* **设备基础配置:** 修正坠落确认时间的验证逻辑 ([6e93ad7](http://43.137.10.199:3000/liujia/ln-web/commits/6e93ad7638accb0f3206cddc500f0a9434219b97))
+
+
+
+## [0.1.10](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.9...v0.1.10) (2025-08-12)
+
+
+### Features
+
+* **布局:** 添加页面刷新功能并优化用户下拉菜单样式 ([df97059](http://43.137.10.199:3000/liujia/ln-web/commits/df9705910762d41aa3e0b4b036d6db84cc756599))
+
+
+
+## [0.1.9](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.8...v0.1.9) (2025-08-12)
+
+
+
+## [0.1.8](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.7...v0.1.8) (2025-08-12)
+
+
+### Bug Fixes
+
+* **上传设备:** 修正上传成功提示和复制按钮样式 ([ed2e559](http://43.137.10.199:3000/liujia/ln-web/commits/ed2e5595be2c1b2bb7241bc8006029121a24c7c7))
+
+
+
+## [0.1.7](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.6...v0.1.7) (2025-08-12)
+
+
+### Bug Fixes
+
+* **上传设备:** 修复文件拖拽验证和上传错误处理问题 ([ca532fd](http://43.137.10.199:3000/liujia/ln-web/commits/ca532fdc38ee34b4ee2a4bdf6ef6601aec7fccb6))
+
+
+
+## [0.1.6](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.5...v0.1.6) (2025-08-12)
+
+
+### Bug Fixes
+
+* **设备管理:** 移除归属租户的必填验证规则 ([48c1d09](http://43.137.10.199:3000/liujia/ln-web/commits/48c1d092bfdc3c6241262f998fa2af5cd4d1986c))
+
+
+
+## [0.1.5](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.4...v0.1.5) (2025-08-12)
+
+
+
+## [0.1.4](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.3...v0.1.4) (2025-08-12)
+
+
+### Bug Fixes
+
+* **设备管理:** 修正设备ID验证错误信息并调整Docker构建命令 ([5ec332a](http://43.137.10.199:3000/liujia/ln-web/commits/5ec332a5fc77bc31a8501712399a2cf49f8e54a9))
+
+
+
+## [0.1.3](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.2...v0.1.3) (2025-08-12)
+
+
+
+## [0.1.2](http://43.137.10.199:3000/liujia/ln-web/compare/v0.1.1...v0.1.2) (2025-08-12)
+
+
+### Features
+
+* 调整设备点位超时时间为1秒; ([2997285](http://43.137.10.199:3000/liujia/ln-web/commits/29972853ae0684651dab5e56dc8e927740ca0c13))
+* 更新忽略文件的类型 ([a019986](http://43.137.10.199:3000/liujia/ln-web/commits/a0199869d7aea009c0caadbe8bbb1afc9b490bbd))
+* 路由守卫去除重定向功能; ([dca2284](http://43.137.10.199:3000/liujia/ln-web/commits/dca2284ada998aa6ab7e231581bd75fb63f35766))
+* 删除冗余脚本文件; ([ac4f164](http://43.137.10.199:3000/liujia/ln-web/commits/ac4f1647fd500a68ce02f2319c74b6fcdd161a44))
+* 新增 npm-run-all 依赖并调整部署脚本; ([ada9021](http://43.137.10.199:3000/liujia/ln-web/commits/ada90212aedd6764b8230810c09f14aad205ec28))
+* 新增合并脚本 ([9e5617b](http://43.137.10.199:3000/liujia/ln-web/commits/9e5617b0514512f226b6a39cec612e0e3ba0f3a3))
+* **scripts:** 添加合并dev到prod分支的脚本;展示设备详情的mqtt消息的打印; ([f75c721](http://43.137.10.199:3000/liujia/ln-web/commits/f75c721ffe313f78e8ec34aa91ecf7d9f184d588))
+
+
+
+## [0.1.1](http://43.137.10.199:3000/liujia/ln-web/compare/7d418fcd64569ccec29cb2dedf24964c054d131e...v0.1.1) (2025-08-11)
+
+
+### Bug Fixes
+
+* 解决设备清单中文乱码的问题; ([1d27061](http://43.137.10.199:3000/liujia/ln-web/commits/1d270619a8fd7e5ff7f78f6c8f4b4265ba56038c))
+* **Jenkinsfile:** 更新Jenkinsfile文件 ([a8a85fb](http://43.137.10.199:3000/liujia/ln-web/commits/a8a85fbf3bae561ce6a6cac79b430eab79028768))
+
+
+### Features
+
+* **布局:** 添加返回按钮状态管理和导航历史追踪 ([6151e93](http://43.137.10.199:3000/liujia/ln-web/commits/6151e9351d90ce65a7167c121056394eda2cc302))
+* 调整mqtt与接口的地址; ([6507809](http://43.137.10.199:3000/liujia/ln-web/commits/65078097c3735434dce2f9a9fe3e15af6e39a445))
+* **环境配置:** 新增单环境配置并优化代理设置 ([48ab50c](http://43.137.10.199:3000/liujia/ln-web/commits/48ab50c9fba23935a959316c52433ed5ed84e114))
+* 迁移项目; ([7d418fc](http://43.137.10.199:3000/liujia/ln-web/commits/7d418fcd64569ccec29cb2dedf24964c054d131e))
+* 添加测试环境配置并优化构建脚本 ([3e18585](http://43.137.10.199:3000/liujia/ln-web/commits/3e185854ea1d0b7cc05db70d53a16be0bc585618))
+* 添加应用版本显示功能 ([5da1efd](http://43.137.10.199:3000/liujia/ln-web/commits/5da1efde3caae3865b91f5dc282c13afda556fc6))
+* 新增前端部署脚本; ([046a48e](http://43.137.10.199:3000/liujia/ln-web/commits/046a48eb79f25fb94b2a6ee0ff33a1b21dc4c581))
+* 重构构建部署流程并优化登录页 ([36b249d](http://43.137.10.199:3000/liujia/ln-web/commits/36b249d885f2d65e11370f88611cc7749d674436))
+* **deploy:** 改进前端部署脚本实现原子化部署 ([2718a52](http://43.137.10.199:3000/liujia/ln-web/commits/2718a526b6de1e18ea72af22c65812ed8d389490))
+* mqtt调整为域名; ([760653c](http://43.137.10.199:3000/liujia/ln-web/commits/760653c242bb4111a505d311e7ba3cebde7d3be4))
+
+
+

+ 7 - 3
package.json

@@ -1,6 +1,6 @@
 {
   "name": "vue-project",
-  "version": "0.1.11",
+  "version": "0.1.20",
   "private": true,
   "type": "module",
   "scripts": {
@@ -10,8 +10,10 @@
     "build:dev": "vite build --mode development",
     "build:test": "vite build --mode test",
     "build": "vite build",
-    "bump": "npm version patch -m \"new version published: v%s\"",
-    "release": "npm run bump && git push && git push --tags && node scripts/release-message.js",
+    "bump": "npm version patch -m \"feat: new version published: v%s\"",
+    "release": "node scripts/release.js",
+    "changelog": "npx conventional-changelog -p angular -i CHANGELOG.md -s",
+    "changelog:all": "npx conventional-changelog -p angular -i CHANGELOG.md -s -r 0",
     "deploy:test": "npm-run-all build:test run:deploy",
     "run:deploy": "pwsh -ExecutionPolicy Bypass -File scripts/deploy.ps1",
     "preview": "vite preview",
@@ -46,11 +48,13 @@
     "@vue/eslint-config-prettier": "^10.2.0",
     "@vue/eslint-config-typescript": "^14.5.1",
     "@vue/tsconfig": "^0.7.0",
+    "conventional-changelog-cli": "^5.0.0",
     "eslint": "^9.29.0",
     "eslint-import-resolver-alias": "^1.1.2",
     "eslint-plugin-import": "^2.32.0",
     "eslint-plugin-prettier": "^5.5.1",
     "eslint-plugin-vue": "~10.2.0",
+    "inquirer": "^12.9.1",
     "jiti": "^2.4.2",
     "less": "^4.3.0",
     "npm-run-all": "^4.1.5",

Datei-Diff unterdrückt, da er zu groß ist
+ 633 - 0
pnpm-lock.yaml


+ 44 - 0
scripts/release.js

@@ -0,0 +1,44 @@
+#!/usr/bin/env node
+import { execSync } from 'child_process'
+import inquirer from 'inquirer'
+
+function run(cmd) {
+  execSync(cmd, { stdio: 'inherit' })
+}
+
+async function main() {
+  console.log('🚀 开始发布流程...')
+
+  // 1. 选择版本类型
+  const { versionType } = await inquirer.prompt([
+    {
+      type: 'list',
+      name: 'versionType',
+      message: '请选择版本类型:',
+      choices: [
+        { name: '补丁版本 (patch)', value: 'patch' },
+        { name: '小版本 (minor)', value: 'minor' },
+        { name: '大版本 (major)', value: 'major' },
+      ],
+    },
+  ])
+
+  // 2. 先更新版本号(生成新 tag)
+  run(`npm version ${versionType} -m "new version published: v%s"`)
+
+  // 3. 全量生成 changelog(覆盖原文件)
+  console.log('📝 正在全量生成 changelog...')
+  run('npx conventional-changelog -p angular -i CHANGELOG.md -s -r 0')
+
+  // 4. 自动提交 changelog
+  run('git add CHANGELOG.md')
+  run('git commit --amend --no-edit') // 直接加到刚才的版本提交里
+
+  // 5. 推送代码 & tag(tag 不变,提交更新了)
+  run('git push --force-with-lease')
+  run('git push --tags')
+
+  console.log('✅ 发布完成!')
+}
+
+main()

Einige Dateien werden nicht angezeigt, da zu viele Dateien in diesem Diff geändert wurden.