鸿蒙入门到实战开发 - DevEco Studio 开发工具

HUAWEI DevEco Studio 基于IntelliJ IDEA Community开源版本定制开发,支持HarmonyOS和OpenHarmony应用及服务开发。

面向全场景多设备,提供一站式的分布式应用开发平台,支持分布式多端开发、分布式多端调测、多端模拟仿真,全方位的质量与安全保障。

DevEco Studio 3.1配套支持HarmonyOS 3.1版本及以上的应用及服务开发,提供了代码智能编辑、低代码开发、双向预览等功能,以及轻量构建工具DevEco Hvigor 、本地模拟器,持续提升应用及服务开发效率。

developer.harmonyos.com/cn/develop/...

下载安装完事遇到这么一个问题

ruby 复制代码
Unable to run 'npm install'.
	 Detail: See https://developer.harmonyos.com/en/docs/documentation/doc-guides/faq-development-environment-0000001168829643#section1311117111474
> hvigor ERROR: Sdk download failed.
> hvigor ERROR: BUILD FAILED in 9 s 401 ms 

刚上来创建一个项目

项目结构

安装文档执行这一步也失败了。。。

ruby 复制代码
Install task failed: JS 3.2.12.5.
Install JS dependencies failed.
Cause: Unable to run npm install.
Solution: See https://developer.harmonyos.com/cn/docs/documentation/doc-guides/faq-development-environment-0000001168829643#section1311117111474

文档说需要来这里清缓存,我打开后发现没有缓存但是也装模作样的清了一下

看到这些就是可以了

shell 复制代码
> hvigor 'npm install' executed
> hvigor Moving the SDK...
> hvigor Install task finished: ArkTS 3.2.12.5
> hvigor Installing Toolchains:3.2.3.6...
> hvigor Install task started: Toolchains 3.2.3.6
> hvigor Downloading https://update.dbankcdn.com/download/data/pub_13/HWHOTA_hota_900_9/cd/v3/6-Eg0KmCSpOpkqSEm-c8_w/toolchains-darwin-arm64-3.2.3.6-Release.zip...
> hvigor Unzipping /Users/xxx/Library/Huawei/Sdk/.temp/toolchains/3.2.3.6/install/toolchains-darwin-arm64-3.2.3.6-Release.zip...
> hvigor Moving the SDK...
> hvigor Install task finished: Toolchains 3.2.3.6
> hvigor Finished :entry:init... after 2 ms 
> hvigor Finished ::init... after 1 ms 

Process finished with exit code 0

运行App

lua 复制代码
The type of the target device does not match the deviceType configured in the module.json5 file of the selected module.

查了几个文档依然没有解决问题,好挫败啊

developer.huawei.com/consumer/cn...

blog.csdn.net/Calvin_zhou...

developer.huawei.com/consumer/cn...

我心想是不是没有模拟器、打算去下载一个模拟器,然后提示我需要先下载系统,玩呢?

然后我把这一堆都下载了

然后就安装了这个

可是我还么有运行起来程序,我累了。。。

相关推荐
Georgewu3 小时前
【HarmonyOS 5】桌面快捷方式功能实现详解
harmonyos
娅娅梨4 小时前
HarmonyOS-ArkUI 自定义弹窗
华为·harmonyos·arkts·arkui
陈奕昆4 小时前
3.3 HarmonyOS NEXT原子化服务开发:卡片设计、轻量部署与场景化编排实战
华为·harmonyos
上海张律师8 小时前
鸿蒙ArkTS+ArkUI仿微信消息列表页制作
harmonyos
王二蛋与他的张大花15 小时前
HarmonyOS运动开发:如何用mpchart绘制运动配速图表
harmonyos
程序员小刘15 小时前
【HarmonyOS 5】生活与服务开发实践详解以及服务卡片案例
华为·生活·harmonyos
小草帽学编程19 小时前
鸿蒙Next开发真机调试签名申请流程
android·华为·harmonyos
陈奕昆19 小时前
5.2 HarmonyOS NEXT应用性能诊断与优化:工具链、启动速度与功耗管理实战
华为·harmonyos
哼唧唧_1 天前
React Native开发鸿蒙运动健康类应用的项目实践记录
react native·harmonyos·harmony os5·运动健康