pysunday / rs-reverse

瑞数vmp纯算法逆向,补环境框架sdenv的灵感来源
BSD 3-Clause "New" or "Revised" License
326 stars 197 forks source link

执行命令出错 #2

Closed Smawexi closed 10 months ago

Smawexi commented 10 months ago

D:\Test\test\rs>npx rs-reverse makecode -u http://wcjs.sbj.cnipa.gov.cn/sgtmi C:\Users\12817\AppData\Local\npm-cache_npx\8d44cd73943023ee\node_modules\module-alias\index.js:184 throw new Error('Unable to find package.json in any of:\n[' + pathString + ']') ^

Error: Unable to find package.json in any of: [C:\Users\12817\AppData\Local\npm-cache_npx\8d44cd73943023ee\node_modules\rs-reverse\package.json] at init (C:\Users\12817\AppData\Local\npm-cache_npx\8d44cd73943023ee\node_modules\module-alias\index.js:184:11) at Object. (C:\Users\12817\AppData\Local\npm-cache_npx\8d44cd73943023ee\node_modules\rs-reverse\main.js:3:24) at Module._compile (node:internal/modules/cjs/loader:1105:14) at Module._extensions..js (node:internal/modules/cjs/loader:1159:10) at Module.load (node:internal/modules/cjs/loader:981:32) at Module._load (node:internal/modules/cjs/loader:827:12) at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:77:12) at node:internal/main/run_main_module:17:47

Node.js v18.0.0 Windows10平台

pysunday commented 10 months ago

感谢提供问题!由于三方模块module-alias中代码candidatePackagePaths = [nodePath.resolve(options.base.replace(/\/package\.json$/, ''))] 执行替换文本未兼容windows下的路径连接符,因此传入时提前处理,已在v1.2.1版本修复!