gpt4 book ai didi

android - 找不到模块 'which' - Cordova android

转载 作者:太空宇宙 更新时间:2023-11-03 12:18:11 25 4
gpt4 key购买 nike

我正在尝试通过执行以下命令来构建我的 cordova 构建

cordova -d build android

但我遇到以下错误。

module.js:340
throw err;
Error: Cannot find module 'which'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Module.require (module.js:364:17)
at require (module.js:380:17)

有谁知道原因吗?我检查了我的路径中是否有我的 ANT_HOME/ANDROID_HOME,但我不确定错误背后的原因是什么。

顺便说一句,我正在运行 windows 7 64 位

最佳答案

类似于this question的答案,我的解决方案是

$cordova platform remove android
$cordova platform add android

关于android - 找不到模块 'which' - Cordova android,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26837350/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com