crabatool 1.0.283 → 1.0.285

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.
Files changed (2) hide show
  1. package/package.json +2 -2
  2. package/tool/hash.js +4 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "crabatool",
3
- "version": "1.0.283",
3
+ "version": "1.0.285",
4
4
  "description": "crabatool",
5
5
  "main": "index.js",
6
6
  "bin": {
@@ -17,7 +17,7 @@
17
17
  "upload": "node run.js -upload -version master -Debug true -host http://127.0.0.1:9998 -hidejspath true -targetPath F:\\CarpaNET_NEW",
18
18
  "crabaNgp": "node run.js -mergejs -hidejspath true -targetPath F:\\CarpaNET_NEW\\src\\Carpa.Web\\js\\crabaNgp -inNames initMs.js,businessControl.js -outName F:\\CarpaMS\\src\\js\\crabaNgp.js",
19
19
  "webPath": "node ./test/test.js -checkjs -webhooks 0 -webPath F:\\crabaevery\\www -modName crabaevery",
20
- "makeHash": "node run.js -makeHash -files http://crabadoc.ca.com/js/utils/utils.js,F:/newcrabadoc/www/js/utils/utils.js,./test/test.js,./test/beefun.js,https://s5.vip.wpscdn.cn/web-libs/2t/js/userinfo-collect/1.0.3/vas2t-userinfo-collect.min.js?a=1 -outJson ./hash.json -hashName sha384"
20
+ "makeHash": "node run.js -makeHash -webPath ./test/ -modName craba -files http://crabadoc.ca.com/js/utils/utils.js,F:/newcrabadoc/www/js/utils/utils.js,./test/test.js,./test/beefun.js,https://s5.vip.wpscdn.cn/web-libs/2t/js/userinfo-collect/1.0.3/vas2t-userinfo-collect.min.js?a=1 -outJson ./hash.json -hashName sha384"
21
21
  },
22
22
  "author": "wssf",
23
23
  "dependencies": {
package/tool/hash.js CHANGED
@@ -38,9 +38,10 @@ module.exports.start = function() {
38
38
  // 转为相对webPath的路径
39
39
  if (!isHttp) {
40
40
  f = path.resolve(f);
41
- f = f.replace(config.webPath, '');
42
- if (config.modeName) {
43
- f = path.join(config.modeName, f);
41
+ var webPath = path.resolve(config.webPath);
42
+ f = f.replace(webPath, '');
43
+ if (config.modName) {
44
+ f = path.join(config.modName, f);
44
45
  }
45
46
  f = f.replace('\\', '/');
46
47
  }