gpt4 book ai didi

java - 检测到 Android Studio 项目

转载 作者:行者123 更新时间:2023-12-02 02:14:30 24 4
gpt4 key购买 nike

我是初学者程序员。我需要一些帮助,因为我正在尝试将 HTML 5 网站转换为 Android 应用程序和 IOS 应用程序,

但是我有以下问题:

D:\andriod\anditest1>cordova build android --verbose
No scripts found for hook "before_build".
No scripts found for hook "before_prepare".
Checking config.xml and package.json for saved platforms that haven't been added to the project
Config.xml and package.json platforms are the same. No pkg.json modification.
Package.json and config.xml platforms are different. Updating config.xml with most current list of platforms.
PlatformApi successfully found for platform android
Android Studio project detected
Checking config.xml for saved plugins that haven't been added to the project
Checking for any plugins added to the project that have not been installed in android platform
No differences found between plugins added to project and installed in android platform. Continuing...
Generating platform-specific config.xml from defaults for android at D:\andriod\anditest1\platforms\android\app\src\main\res\xml\config.xml
Merging project's config.xml into platform-specific android config.xml
Merging and updating files from [www, platforms\android\platform_www] to platforms\android\app\src\main\assets\www
Wrote out android application name "THMLhybrid" to D:\andriod\anditest1\platforms\android\app\src\main\res\values\strings.xml
android-versionCode not found in config.xml. Generating a code based on version in config.xml (1.0.0): 10000
Wrote out Android package name "com.cmsfreindly.com" to D:\andriod\anditest1\platforms\android\app\src\main\java\com\cmsfreindly\com\MainActivity.java
This app does not have launcher icons defined
This app does not have splash screens defined
This app does not have additional resource files defined
Prepared android project successfully
No scripts found for hook "after_prepare".
No scripts found for hook "before_compile".
(node:2340) UnhandledPromiseRejectionWarning: CordovaError: Failed to find 'ANDROID_HOME' environment variable. Try setting it manually.
Failed to find 'android' command in your 'PATH'. Try update your 'PATH' to include path to valid SDK directory.
at D:\andriod\anditest1\platforms\android\cordova\lib\check_reqs.js:305:19
at _fulfilled (D:\andriod\anditest1\platforms\android\cordova\node_modules\q\q.js:854:54)
at self.promiseDispatch.done (D:\andriod\anditest1\platforms\android\cordova\node_modules\q\q.js:883:30)
at Promise.promise.promiseDispatch (D:\andriod\anditest1\platforms\android\cordova\node_modules\q\q.js:816:13)
at D:\andriod\anditest1\platforms\android\cordova\node_modules\q\q.js:877:14
at runSingle (D:\andriod\anditest1\platforms\android\cordova\node_modules\q\q.js:137:13)
at flush (D:\andriod\anditest1\platforms\android\cordova\node_modules\q\q.js:125:13)
at _combinedTickCallback (internal/process/next_tick.js:131:7)
at process._tickCallback (internal/process/next_tick.js:180:9)
at Function.Module.runMain (module.js:695:11)
(node:2340) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:2340) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

D:\andriod\anditest1>

除了java oracle之外,还缺少什么工具需要下载吗?

最佳答案

您需要下载Android Studio并确保路径位于环境变量ANDROID_HOME中。您还需要 Java SE 开发工具包 8u162。

Android 工作室 https://developer.android.com/studio/index.html

Java http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

关于java - 检测到 Android Studio 项目,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49488620/

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