@yangrunchi/a_6 1.0.9 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -78,8 +78,7 @@ try {
78
78
  }
79
79
 
80
80
  // 自动获取 SVN 账户名(覆盖 config.author)
81
- const projectRootForAuthor = path.resolve(__dirname, '../../..');
82
- config.author = getSVNAuthor(projectRootForAuthor, config.author);
81
+ config.author = getSVNAuthor(projectRoot, config.author);
83
82
  console.log('✅ 已加载配置, 作者:', config.author);
84
83
 
85
84
  console.log('🚀 开始生成 funcData 类...');
@@ -133,7 +132,8 @@ function commitToSvn(filePath, action, responseCount = 0, requestCount = 0) {
133
132
 
134
133
  try {
135
134
  const fileName = path.basename(filePath);
136
- const projectRootForSvn = path.resolve(__dirname, '../../..');
135
+ // 使用模块级 projectRoot 而非 __dirname 推算(npm 全局安装时 __dirname 在 node_modules 下)
136
+ const projectRootForSvn = projectRoot;
137
137
 
138
138
  let isVersioned = false;
139
139
  try {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yangrunchi/a_6",
3
- "version": "1.0.9",
3
+ "version": "1.1.0",
4
4
  "description": "996M2 客户端 Node.js 工具集 — 协议同步、自动生成代码、CSV配置、SVN管理、BAT脚本管理器",
5
5
  "main": "index.js",
6
6
  "bin": {