neo-cmp-cli 1.2.16 → 1.2.18

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "neo-cmp-cli",
3
- "version": "1.2.16",
3
+ "version": "1.2.18",
4
4
  "description": "前端脚手架:自定义组件开发工具,支持react 和 vue2.0技术栈。",
5
5
  "keywords": [
6
6
  "neo-cli",
@@ -1,6 +1,7 @@
1
1
  const { aliBOS, baiduBOS } = require('akfun');
2
2
  const fs = require('fs');
3
3
  const path = require('path');
4
+ const _ = require('lodash');
4
5
  const { catchCurPackageJson } = require('../utils/pathUtils');
5
6
  const getConfigObj = require('../utils/getConfigObj');
6
7
  const updatePublishLog = require('../cmpUtils/updatePublishLog');
@@ -185,13 +186,25 @@ const getResultFilesByWidgetName = (files) => {
185
186
  return;
186
187
  }
187
188
  let widgetName = file.widgetName;
189
+ const curCmpInfo = {
190
+ 'cmpType': _.kebabCase(widgetName),
191
+ }
192
+
188
193
  if (widgetName.includes('Model')) {
189
194
  widgetName = widgetName.replace('Model', '');
195
+ curCmpInfo.cmpType = _.kebabCase(widgetName),
196
+ curCmpInfo.modelAsset = !file.success ? `${file.error}[${file.ossPath}]` : file.ossPath;
197
+ } else if (file.fileName.endsWith('.css')) {
198
+ curCmpInfo.cssAsset = !file.success ? `${file.error}[${file.ossPath}]` : file.ossPath;
199
+ } else {
200
+ curCmpInfo.asset = !file.success ? `${file.error}[${file.ossPath}]` : file.ossPath;
190
201
  }
202
+
191
203
  if (widgetFilesMap[widgetName]) {
192
- widgetFilesMap[widgetName].push(getResultFile(file));
204
+ widgetFilesMap[widgetName] = Object.assign(widgetFilesMap[widgetName], curCmpInfo);
193
205
  } else {
194
- widgetFilesMap[widgetName] = [getResultFile(file)];
206
+ // widgetFilesMap[widgetName] = [getResultFile(file)];
207
+ widgetFilesMap[widgetName] = curCmpInfo;
195
208
  }
196
209
  });
197
210
 
@@ -47,7 +47,7 @@
47
47
  "@commitlint/config-conventional": "^9.1.1",
48
48
  "@types/react": "^16.9.11",
49
49
  "@types/react-dom": "^16.9.15",
50
- "neo-cmp-cli": "^1.2.16",
50
+ "neo-cmp-cli": "^1.2.18",
51
51
  "husky": "^4.2.5",
52
52
  "lint-staged": "^10.2.9",
53
53
  "prettier": "^2.0.5"
@@ -51,7 +51,7 @@
51
51
  "@types/react": "^16.9.11",
52
52
  "@types/react-dom": "^16.9.15",
53
53
  "@types/axios": "^0.14.0",
54
- "neo-cmp-cli": "^1.2.16",
54
+ "neo-cmp-cli": "^1.2.18",
55
55
  "husky": "^4.2.5",
56
56
  "lint-staged": "^10.2.9",
57
57
  "prettier": "^2.0.5"
@@ -47,7 +47,7 @@
47
47
  "@commitlint/config-conventional": "^9.1.1",
48
48
  "@types/react": "^16.9.11",
49
49
  "@types/react-dom": "^16.9.15",
50
- "neo-cmp-cli": "^1.2.16",
50
+ "neo-cmp-cli": "^1.2.18",
51
51
  "husky": "^4.2.5",
52
52
  "lint-staged": "^10.2.9",
53
53
  "prettier": "^2.0.5",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "neo-custom-cmp-template",
3
- "version": "1.1.2",
3
+ "version": "1.1.6",
4
4
  "description": "neo自定义组件模板(react&ts技术栈)",
5
5
  "keywords": [
6
6
  "自定义组件模板",
@@ -52,7 +52,7 @@
52
52
  "@types/react": "^16.9.11",
53
53
  "@types/react-dom": "^16.9.15",
54
54
  "@types/axios": "^0.14.0",
55
- "neo-cmp-cli": "^1.2.16",
55
+ "neo-cmp-cli": "^1.2.18",
56
56
  "husky": "^4.2.5",
57
57
  "lint-staged": "^10.2.9",
58
58
  "prettier": "^2.0.5"
@@ -44,7 +44,7 @@
44
44
  "devDependencies": {
45
45
  "@commitlint/cli": "^8.3.5",
46
46
  "@commitlint/config-conventional": "^9.1.1",
47
- "neo-cmp-cli": "^1.2.16",
47
+ "neo-cmp-cli": "^1.2.18",
48
48
  "husky": "^4.2.5",
49
49
  "lint-staged": "^10.2.9",
50
50
  "prettier": "^2.0.5"
@@ -46,7 +46,7 @@
46
46
  "@commitlint/config-conventional": "^9.1.1",
47
47
  "@types/react": "^16.9.11",
48
48
  "@types/react-dom": "^16.9.15",
49
- "neo-cmp-cli": "^1.2.16",
49
+ "neo-cmp-cli": "^1.2.18",
50
50
  "husky": "^4.2.5",
51
51
  "lint-staged": "^10.2.9",
52
52
  "prettier": "^2.0.5"
@@ -44,7 +44,7 @@
44
44
  "devDependencies": {
45
45
  "@commitlint/cli": "^8.3.5",
46
46
  "@commitlint/config-conventional": "^9.1.1",
47
- "neo-cmp-cli": "^1.2.16",
47
+ "neo-cmp-cli": "^1.2.18",
48
48
  "husky": "^4.2.5",
49
49
  "lint-staged": "^10.2.9",
50
50
  "prettier": "^2.0.5",