diff --git a/en/application-dev/quick-start/Readme-EN.md b/en/application-dev/quick-start/Readme-EN.md index 2cb67b25eb2d9d278abc99bfed1d4a9c87a890c4..72c8f73f67e21dfd81b7a542a4e4e60292e8bdb6 100644 --- a/en/application-dev/quick-start/Readme-EN.md +++ b/en/application-dev/quick-start/Readme-EN.md @@ -3,6 +3,7 @@ - [DevEco Studio \(OpenHarmony\) User Guide](deveco-studio-(openharmony)-user-guide.md) - [Overview](overview.md) - [Configuring the OpenHarmony SDK](configuring-the-openharmony-sdk.md) + - [Importing an OpenHarmony Project](importing-an-openharmony-project.md) - [Configuring the OpenHarmony App Signature](configuring-the-openharmony-app-signature.md) - [Installing and Running Your OpenHarmony App](installing-and-running-your-openharmony-app.md) diff --git a/en/application-dev/quick-start/configuring-the-openharmony-app-signature.md b/en/application-dev/quick-start/configuring-the-openharmony-app-signature.md index a88ad4448b862a985099e26a1c87ece9da7ecc30..9f83655c116701963ae726c99fa734da1e9e0004 100644 --- a/en/application-dev/quick-start/configuring-the-openharmony-app-signature.md +++ b/en/application-dev/quick-start/configuring-the-openharmony-app-signature.md @@ -71,24 +71,21 @@ Refer to the following descriptions about the parameters in the command: Before debugging on a real device, use the private key file \(.p12\), certificate file \(.cer\), and profile file \(.p7b\) to sign the target module. -Go to **File** \> **Project Structure**. On the displayed page, go to **Modules** \> _Module name_ \> **Signing Configs**, and set the signing parameters under **debug**. - ->![](public_sys-resources/icon-note.gif) **NOTE:** ->To release a HAP package of the release type, configure the signature information from **Modules** \> _Module name_ \> **Signing Configs** \> **release**. +Go to **File** \> **Project Structure** \> **Project** \> **Signing Configs** \> **debug**, deselect **Automatically generate signing**, and configure the signature information of the specified module. - **Store File**: Select the key store file with the file name extension .p12, which is generated in [Generating a Key Store and CSR](#section153146467405). -- **Store Password**: Enter the key store password. -- **Key Alias**: Enter the alias of the key. -- **Key Password**: Enter the password of the key. +- **Store Password**: Enter the key store password, which is the same as the key store password entered in [Generating a Key Store and CSR](#section153146467405). +- **Key Alias**: Enter the alias of the key, which is the same as the alias entered in [Generating a Key Store and CSR](#section153146467405). +- **Key Password**: Enter the key password, which is the same as the value of **Store Password**. - **Sign Alg**: Specify the signature algorithm, which has a fixed value of **SHA256withECDSA**. - **Profile File**: Select the obtained debug profile in .p7b format. - **Certpath File**: Select the obtained debug certificate in .cer format. -![](figures/en-us_image_0000001160327971.png) +![](figures/en-us_image_0000001117638220.png) -Click **OK** to save your configurations. Then you can view the signature configuration information in **build.gradle** of the module. +Click **OK** to save your configurations. Then you can view the signature configuration information in **build.gradle** of the project. -![](figures/en-us_image_0000001113648168.png) +![](figures/en-us_image_0000001117638526.png) By default, the type of a HAP package compiled using DevEco Studio is set to **debug**. For a release type, click the **OhosBuild Variants** tab in the lower left corner of the project and set the type to **release**. For details about how to compile and build the HAP, see [HUAWEI DevEco Studio User Guide](https://developer.harmonyos.com/en/docs/documentation/doc-guides/build_hap-0000001053342418). @@ -96,5 +93,5 @@ By default, the type of a HAP package compiled using DevEco Studio is set to ** After the compilation is complete, you can obtain the HAP package of your OpenHarmony app from the **build** directory of the project. -![](figures/en-us_image_0000001163552429.png) +![](figures/en-us_image_0000001163918627.png) diff --git a/en/application-dev/quick-start/configuring-the-openharmony-sdk.md b/en/application-dev/quick-start/configuring-the-openharmony-sdk.md index 0b9092aeed1224c7f37d43290a7914021be30660..ae32e56ba6fec38d508d8db67dd0ae06286a26a7 100644 --- a/en/application-dev/quick-start/configuring-the-openharmony-sdk.md +++ b/en/application-dev/quick-start/configuring-the-openharmony-sdk.md @@ -2,7 +2,6 @@ - [Prerequisites](#section164161442154812) - [Configuring the SDK Information](#section1265592425017) -- [Importing the Project](#section12559415183418) To set up the OpenHarmony app development environment, configure the corresponding SDK information in DevEco Studio first. @@ -58,7 +57,7 @@ DevEco Studio manages SDKs and toolchains using SDK Manager. OpenHarmony contain 2. Follow the instructions in DevEco Studio to go to the SDK download page. In the **HarmonyOS SDK Location** field, select the local directory where the SDK package was decompressed, then click **Next**. >![](public_sys-resources/icon-note.gif) **NOTE:** - >If you are not using DevEco Studio for the first time, the SDK download page may not be displayed. In this case, go to **Configure \> Settings \> Appearance & Behavior \> System Settings \> HarmonyOS SDK** and click **HarmonyOS SDK Location** to download the SDK. + >If you are not using DevEco Studio for the first time, the SDK download page may not be displayed. In this case, go to **Configure** \(or ![](figures/en-us_image_0000001117475774.png)\) \> **Settings** \> **Appearance & Behavior** \> **System Settings** \> **HarmonyOS SDK** and click **HarmonyOS SDK Location** to download the SDK. ![](figures/en-us_image_0000001117288684.png) @@ -76,32 +75,3 @@ DevEco Studio manages SDKs and toolchains using SDK Manager. OpenHarmony contain ![](figures/en-us_image_0000001163170097.png) -## Importing the Project - -After the OpenHarmony SDK is configured, you can start developing your app only by **importing a sample project** to begin with. - -1. On the DevEco Studio welcome page, click **Import HarmonyOS Sample** to import a sample project. - - ![](figures/en-us_image_0000001163495457.png) - -2. Go to **ability** \> **HelloWorld** and click **Next**. - - ![](figures/en-us_image_0000001117295732.png) - -3. Configure **App Name** and **Project Location** and click **Finish**. Wait until the sample project is imported. - - ![](figures/en-us_image_0000001163500855.png) - -4. Wait until the project sync is indicated to be failed. Open the **build.gradle** file in the project and change the version number of the HAP plugin to **2.4.4.3-RC**. - - ![](figures/en-us_image_0000001163550987.png) - -5. Click ![](figures/en-us_image_0000001117304698.png) under **Gradle** in the upper right corner to sync the project again. - - ![](figures/en-us_image_0000001117145200.png) - -6. When the project is successfully synced, you can develop your OpenHarmony app. - - ![](figures/en-us_image_0000001117145614.png) - - diff --git a/en/application-dev/quick-start/deveco-studio-(openharmony)-user-guide.md b/en/application-dev/quick-start/deveco-studio-(openharmony)-user-guide.md index eb40937d0debd1f2ad6b0a8c8a1b6aa587e337ef..89f638058e0ce2ebfc083afddc2eae351a94a9d9 100644 --- a/en/application-dev/quick-start/deveco-studio-(openharmony)-user-guide.md +++ b/en/application-dev/quick-start/deveco-studio-(openharmony)-user-guide.md @@ -4,6 +4,8 @@ - **[Configuring the OpenHarmony SDK](configuring-the-openharmony-sdk.md)** +- **[Importing an OpenHarmony Project](importing-an-openharmony-project.md)** + - **[Configuring the OpenHarmony App Signature](configuring-the-openharmony-app-signature.md)** - **[Installing and Running Your OpenHarmony App](installing-and-running-your-openharmony-app.md)** diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001113648168.png b/en/application-dev/quick-start/figures/en-us_image_0000001113648168.png deleted file mode 100644 index 0800e5f036cf8a6d985e43a299c84c2c425a7709..0000000000000000000000000000000000000000 Binary files a/en/application-dev/quick-start/figures/en-us_image_0000001113648168.png and /dev/null differ diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001117475774.png b/en/application-dev/quick-start/figures/en-us_image_0000001117475774.png new file mode 100644 index 0000000000000000000000000000000000000000..74b66efabbbbbea4752f0296985486369a0cdc74 Binary files /dev/null and b/en/application-dev/quick-start/figures/en-us_image_0000001117475774.png differ diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001163550987.png b/en/application-dev/quick-start/figures/en-us_image_0000001117475776.png similarity index 100% rename from en/application-dev/quick-start/figures/en-us_image_0000001163550987.png rename to en/application-dev/quick-start/figures/en-us_image_0000001117475776.png diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001117295732.png b/en/application-dev/quick-start/figures/en-us_image_0000001117635678.png similarity index 100% rename from en/application-dev/quick-start/figures/en-us_image_0000001117295732.png rename to en/application-dev/quick-start/figures/en-us_image_0000001117635678.png diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001117145200.png b/en/application-dev/quick-start/figures/en-us_image_0000001117635680.png similarity index 100% rename from en/application-dev/quick-start/figures/en-us_image_0000001117145200.png rename to en/application-dev/quick-start/figures/en-us_image_0000001117635680.png diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001117638220.png b/en/application-dev/quick-start/figures/en-us_image_0000001117638220.png new file mode 100644 index 0000000000000000000000000000000000000000..52c5bcf093ba6f623b89a846827c834be27937b0 Binary files /dev/null and b/en/application-dev/quick-start/figures/en-us_image_0000001117638220.png differ diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001117638526.png b/en/application-dev/quick-start/figures/en-us_image_0000001117638526.png new file mode 100644 index 0000000000000000000000000000000000000000..bc96dd6e4e4f13971d10eb0d59288544b42eca6e Binary files /dev/null and b/en/application-dev/quick-start/figures/en-us_image_0000001117638526.png differ diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001160327971.png b/en/application-dev/quick-start/figures/en-us_image_0000001160327971.png deleted file mode 100644 index 66fe858ee16f90d191048aaf223b834b0b44b6f2..0000000000000000000000000000000000000000 Binary files a/en/application-dev/quick-start/figures/en-us_image_0000001160327971.png and /dev/null differ diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001163552429.png b/en/application-dev/quick-start/figures/en-us_image_0000001163552429.png deleted file mode 100644 index 6aa12419de3872abcfa5f9218991524e61c6fe35..0000000000000000000000000000000000000000 Binary files a/en/application-dev/quick-start/figures/en-us_image_0000001163552429.png and /dev/null differ diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001163495457.png b/en/application-dev/quick-start/figures/en-us_image_0000001163835551.png similarity index 100% rename from en/application-dev/quick-start/figures/en-us_image_0000001163495457.png rename to en/application-dev/quick-start/figures/en-us_image_0000001163835551.png diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001117304698.png b/en/application-dev/quick-start/figures/en-us_image_0000001163835553.png similarity index 100% rename from en/application-dev/quick-start/figures/en-us_image_0000001117304698.png rename to en/application-dev/quick-start/figures/en-us_image_0000001163835553.png diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001163500855.png b/en/application-dev/quick-start/figures/en-us_image_0000001163915521.png similarity index 100% rename from en/application-dev/quick-start/figures/en-us_image_0000001163500855.png rename to en/application-dev/quick-start/figures/en-us_image_0000001163915521.png diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001117145614.png b/en/application-dev/quick-start/figures/en-us_image_0000001163915523.png similarity index 100% rename from en/application-dev/quick-start/figures/en-us_image_0000001117145614.png rename to en/application-dev/quick-start/figures/en-us_image_0000001163915523.png diff --git a/en/application-dev/quick-start/figures/en-us_image_0000001163918627.png b/en/application-dev/quick-start/figures/en-us_image_0000001163918627.png new file mode 100644 index 0000000000000000000000000000000000000000..6967c6b140c7e07003fc4548989ea78d9e5fc940 Binary files /dev/null and b/en/application-dev/quick-start/figures/en-us_image_0000001163918627.png differ diff --git a/en/application-dev/quick-start/importing-an-openharmony-project.md b/en/application-dev/quick-start/importing-an-openharmony-project.md new file mode 100644 index 0000000000000000000000000000000000000000..50f10cea4e9f7b556beab326b9a36e5a017bc577 --- /dev/null +++ b/en/application-dev/quick-start/importing-an-openharmony-project.md @@ -0,0 +1,29 @@ +# Importing an OpenHarmony Project + +After the OpenHarmony SDK is configured, you can start developing your app only by **importing a sample project** to begin with. + +1. On the DevEco Studio welcome page, click **Import HarmonyOS Sample** to import a sample project. + + ![](figures/en-us_image_0000001163835551.png) + +2. Go to **ability** \> **HelloWorld** and click **Next**. + + ![](figures/en-us_image_0000001117635678.png) + +3. Configure **App Name** and **Project Location** and click **Finish**. Wait until the sample project is imported. + + ![](figures/en-us_image_0000001163915521.png) + +4. Wait until the project sync is indicated to be failed. Open the **build.gradle** file in the project and change the version number of the HAP plugin to **2.4.4.3-RC**. + + ![](figures/en-us_image_0000001117475776.png) + +5. Click ![](figures/en-us_image_0000001163835553.png) under **Gradle** in the upper right corner to sync the project again. + + ![](figures/en-us_image_0000001117635680.png) + +6. When the project is successfully synced, you can develop your OpenHarmony app. + + ![](figures/en-us_image_0000001163915523.png) + + diff --git a/en/application-dev/quick-start/overview.md b/en/application-dev/quick-start/overview.md index 9887d340ebe5b256c3377afdf8e527961383275e..b95219fd34534e849ff3eb14fe99f06f75cacdd8 100644 --- a/en/application-dev/quick-start/overview.md +++ b/en/application-dev/quick-start/overview.md @@ -11,6 +11,7 @@ DevEco Studio is an integrated development environment \(IDE\) of HarmonyOS apps The process of developing an OpenHarmony app using DevEco Studio is the same as that of developing a HarmonyOS app. This document describes the differences between OpenHarmony and HarmonyOS app development. - **Environment setup**: You need to manually configure the SDK for the OpenHarmony app development. For details, see [Configuring the OpenHarmony SDK](configuring-the-openharmony-sdk.md). +- **OpenHarmony project import**: To develop an OpenHarmony app, you can only import a sample project to start with. For details, see [Importing an OpenHarmony Project](importing-an-openharmony-project.md). - **Signature configuration for debugging**: To run an OpenHarmony app on a real device, you need to sign the app first. For instructions, see [Configuring the OpenHarmony App Signature](configuring-the-openharmony-app-signature.md). - **App running on a real device**: To run your app on a real device, you need to use the hdc tool to push the HAP package of the OpenHarmony to the real device for installation. For details, see [Installing and Running Your OpenHarmony App](installing-and-running-your-openharmony-app.md). diff --git a/summary.md b/summary.md index 15c9e79fab066f21d5d76713f214b10ec139a2fa..a36078725aafc4f3ddc139e2e66b19a479eb95ac 100644 --- a/summary.md +++ b/summary.md @@ -377,7 +377,8 @@ - [DevEco Studio(OpenHarmony)使用指南](zh-cn/application-dev/quick-start/DevEco-Studio(OpenHarmony)使用指南.md) - [概述](zh-cn/application-dev/quick-start/概述.md) - [配置OpenHarmony SDK](zh-cn/application-dev/quick-start/配置OpenHarmony-SDK.md) - - [配置OpenHarmony应用签名信息](zh-cn/application-dev/quick-start/配置OpenHarmony应用签名信息.md) + - [导入OpenHarmony工程](zh-cn/application-dev/quick-start/导入OpenHarmony工程.md) + - [配置OpenHarmony应用签名信息](zh-cn/application-dev/quick-start/配置OpenHarmony应用签名信息.md) - [安装运行OpenHarmony应用](zh-cn/application-dev/quick-start/安装运行OpenHarmony应用.md) - [快速入门](zh-cn/application-dev/quick-start/快速入门.md) - [开发准备](zh-cn/application-dev/quick-start/开发准备.md) diff --git "a/zh-cn/application-dev/quick-start/DevEco-Studio\357\274\210OpenHarmony\357\274\211\344\275\277\347\224\250\346\214\207\345\215\227.md" "b/zh-cn/application-dev/quick-start/DevEco-Studio\357\274\210OpenHarmony\357\274\211\344\275\277\347\224\250\346\214\207\345\215\227.md" index 41c19c8e59ab53428824375d32c0e98b333d0447..3b65fa9abb836843cef657deb210f8515c984542 100644 --- "a/zh-cn/application-dev/quick-start/DevEco-Studio\357\274\210OpenHarmony\357\274\211\344\275\277\347\224\250\346\214\207\345\215\227.md" +++ "b/zh-cn/application-dev/quick-start/DevEco-Studio\357\274\210OpenHarmony\357\274\211\344\275\277\347\224\250\346\214\207\345\215\227.md" @@ -4,6 +4,8 @@ - **[配置OpenHarmony SDK](配置OpenHarmony-SDK.md)** +- **[导入OpenHarmony工程](导入OpenHarmony工程.md)** + - **[配置OpenHarmony应用签名信息](配置OpenHarmony应用签名信息.md)** - **[安装运行OpenHarmony应用](安装运行OpenHarmony应用.md)** diff --git a/zh-cn/application-dev/quick-start/Readme-CN.md b/zh-cn/application-dev/quick-start/Readme-CN.md index ffde2371eaa2520211bf6090c1ab34d47b8fbf75..e725b6a53ab855472ab287dc4feb6a15f7f56ea1 100755 --- a/zh-cn/application-dev/quick-start/Readme-CN.md +++ b/zh-cn/application-dev/quick-start/Readme-CN.md @@ -3,9 +3,11 @@ - [DevEco Studio(OpenHarmony)使用指南](DevEco-Studio(OpenHarmony)使用指南.md) - [概述](概述.md) - [配置OpenHarmony SDK](配置OpenHarmony-SDK.md) + - [导入OpenHarmony工程](导入OpenHarmony工程.md) - [配置OpenHarmony应用签名信息](配置OpenHarmony应用签名信息.md) - [安装运行OpenHarmony应用](安装运行OpenHarmony应用.md) +- [包结构说明](包结构说明.md) - [快速入门](快速入门.md) - [开发准备](开发准备.md) - [使用JS语言开发](使用JS语言开发.md) diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001113648168.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001113648168.png deleted file mode 100644 index 0800e5f036cf8a6d985e43a299c84c2c425a7709..0000000000000000000000000000000000000000 Binary files a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001113648168.png and /dev/null differ diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117475774.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117475774.png new file mode 100644 index 0000000000000000000000000000000000000000..74b66efabbbbbea4752f0296985486369a0cdc74 Binary files /dev/null and b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117475774.png differ diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163550987.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117475776.png similarity index 100% rename from zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163550987.png rename to zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117475776.png diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117295732.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117635678.png similarity index 100% rename from zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117295732.png rename to zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117635678.png diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117145200.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117635680.png similarity index 100% rename from zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117145200.png rename to zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117635680.png diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117638220.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117638220.png new file mode 100644 index 0000000000000000000000000000000000000000..52c5bcf093ba6f623b89a846827c834be27937b0 Binary files /dev/null and b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117638220.png differ diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117638526.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117638526.png new file mode 100644 index 0000000000000000000000000000000000000000..bc96dd6e4e4f13971d10eb0d59288544b42eca6e Binary files /dev/null and b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117638526.png differ diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001160327971.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001160327971.png deleted file mode 100644 index 66fe858ee16f90d191048aaf223b834b0b44b6f2..0000000000000000000000000000000000000000 Binary files a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001160327971.png and /dev/null differ diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163552429.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163552429.png deleted file mode 100644 index 6aa12419de3872abcfa5f9218991524e61c6fe35..0000000000000000000000000000000000000000 Binary files a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163552429.png and /dev/null differ diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163495457.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163835551.png similarity index 100% rename from zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163495457.png rename to zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163835551.png diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117304698.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163835553.png similarity index 100% rename from zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117304698.png rename to zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163835553.png diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163500855.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163915521.png similarity index 100% rename from zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163500855.png rename to zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163915521.png diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117145614.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163915523.png similarity index 100% rename from zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001117145614.png rename to zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163915523.png diff --git a/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163918627.png b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163918627.png new file mode 100644 index 0000000000000000000000000000000000000000..6967c6b140c7e07003fc4548989ea78d9e5fc940 Binary files /dev/null and b/zh-cn/application-dev/quick-start/figures/zh-cn_image_0000001163918627.png differ diff --git "a/zh-cn/application-dev/quick-start/\345\214\205\347\273\223\346\236\204\350\257\264\346\230\216.md" "b/zh-cn/application-dev/quick-start/\345\214\205\347\273\223\346\236\204\350\257\264\346\230\216.md" new file mode 100644 index 0000000000000000000000000000000000000000..94c83987ac62055ee5a990bf83f18c995ddc354e --- /dev/null +++ "b/zh-cn/application-dev/quick-start/\345\214\205\347\273\223\346\236\204\350\257\264\346\230\216.md" @@ -0,0 +1,75 @@ +# 包结构说明 + +在应用开发的工程中,需要在config.json配置文件中对应用的包结构进行声明。 + +配置文件示例如下: + +``` +{ + "app": { + "bundleName": "com.example.myapplication", + "vendor": "example", + "version": { + "code": 1, + "name": "1.0" + }, + "apiVersion": { + "compatible": 4, + "target": 5, + "releaseType": "Beta1" + } + }, + "deviceConfig": {}, + "module": { + "package": "com.example.myapplication.entrymodule", + "name": ".MyApplication", + "deviceType": [ + "phone" + ], + "distro": { + "deliveryWithInstall": true, + "moduleName": "entry", + "moduleType": "entry" + }, + "abilities": [ + { + "skills": [ + { + "entities": [ + "entity.system.home" + ], + "actions": [ + "action.system.home" + ] + } + ], + "name": "com.example.myapplication.entrymodule.MainAbility", + "icon": "$media:icon", + "description": "$string:mainability_description", + "label": "$string:app_name", + "type": "page", + "launchType": "standard" + } + ], + "js": [ + { + "pages": [ + "pages/index/index" + ], + "name": "default", + "window": { + "designWidth": 720, + "autoDesignWidth": false + } + } + ] + } +} +``` + +**包结构声明需要注意以下约束:** + +- "package"字段命名要保证在相同bundleName的应用内唯一。 +- "abilities"字段下只能声明一个ability。 +- "abilities"字段中ability的"name"字段命名要保证在相同bundleName的应用内唯一。 + diff --git "a/zh-cn/application-dev/quick-start/\345\257\274\345\205\245OpenHarmony\345\267\245\347\250\213.md" "b/zh-cn/application-dev/quick-start/\345\257\274\345\205\245OpenHarmony\345\267\245\347\250\213.md" new file mode 100644 index 0000000000000000000000000000000000000000..3d0571cdc4f5b4c1bd7474fe8372ca2f5f235077 --- /dev/null +++ "b/zh-cn/application-dev/quick-start/\345\257\274\345\205\245OpenHarmony\345\267\245\347\250\213.md" @@ -0,0 +1,29 @@ +# 导入OpenHarmony工程 + +OpenHarmony SDK配置完成后,便可以启动应用开发。针对OpenHarmony应用开发,**只能通过导入Sample工程的方式来创建一个新工程**。 + +1. 在DevEco Studio的欢迎页,点击**Import HarmonyOS Sample**按钮,导入Sample工程。 + + ![](figures/zh-cn_image_0000001163835551.png) + +2. 选择ability下的**HelloWorld**工程,然后点击**Next**。 + + ![](figures/zh-cn_image_0000001117635678.png) + +3. 设置**App Name**和**Project Location**,然后点击**Finish**,等待Sample工程导入完成。 + + ![](figures/zh-cn_image_0000001163915521.png) + +4. Sample导入后,等待工程同步完成,此时工程会同步失败。请打开工程下的build.gradle,修改hap插件的版本号为“2.4.4.3-RC”。 + + ![](figures/zh-cn_image_0000001117475776.png) + +5. 修改完成后,点击右上角Gradle中的![](figures/zh-cn_image_0000001163835553.png)按钮,重新同步工程。 + + ![](figures/zh-cn_image_0000001117635680.png) + +6. 等待工程同步完成,同步成功后,便可以进行OpenHarmony应用开发了。 + + ![](figures/zh-cn_image_0000001163915523.png) + + diff --git "a/zh-cn/application-dev/quick-start/\346\246\202\350\277\260.md" "b/zh-cn/application-dev/quick-start/\346\246\202\350\277\260.md" index 40216189d795aebfd368015bad78775ce9e6d4a5..fbfe84ac6edacda059405207522eb0c6886e0b9e 100644 --- "a/zh-cn/application-dev/quick-start/\346\246\202\350\277\260.md" +++ "b/zh-cn/application-dev/quick-start/\346\246\202\350\277\260.md" @@ -8,9 +8,10 @@ DevEco Studio是HarmonyOS的配套的开发IDE,因为HarmonyOS是基于OpenHarmony开发的,因此,使用DevEco Studio(配套HarmonyOS)也可以进行OpenHarmony的应用开发。 -使用DevEco Studio开发OpenHarmony应用的流程与开发HarmonyOS的流程完全一样,本文档仅描述OpenHarmony应用开发与HarmonyOS应用开发的差异点。 +使用DevEco Studio开发开发OpenHarmony应用的流程与开发HarmonyOS的流程完全一样,本文档仅描述OpenHarmony应用开发与HarmonyOS应用开发的差异点。 - **搭建开发环境差异**:OpenHarmony应用开发环境需要开发者手动配置SDK,具体可参考[配置OpenHarmony SDK](配置OpenHarmony-SDK.md)章节。 +- **导入OpenHarmony工程**:OpenHarmony应用开发,只能通过导入Sample工程的方式来创建一个新工程,具体可参考[导入OpenHarmony工程](导入OpenHarmony工程.md)。 - **调试签名配置**:OpenHarmony应用运行在真机设备上,需要对应用进行签名,关于OpenHarmony应用的签名指导请参考[配置OpenHarmony应用签名信息](配置OpenHarmony应用签名信息.md)。 - **在真机设备上运行应用**:需要使用hdc工具将OpenHarmony的hap包推送到真机设备上进行安装,具体可参考[安装运行OpenHarmony应用](安装运行OpenHarmony应用.md)。 diff --git "a/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony-SDK.md" "b/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony-SDK.md" index f4e248ad52490e8f3735883c49f0ea98ebe649f5..bcb326f7ddbe103fbf5b7d0ad479897e7cd3186e 100644 --- "a/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony-SDK.md" +++ "b/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony-SDK.md" @@ -2,7 +2,6 @@ - [前提条件](#section164161442154812) - [配置SDK信息](#section1265592425017) -- [导入工程](#section12559415183418) 在设置OpenHarmony应用开发环境时,需要开发者在DevEco Studio中配置对应的SDK信息。 @@ -58,7 +57,7 @@ DevEco Studio通过SDK Manager统一管理SDK及工具链,OpenHarmony包含如 2. 接下来DevEco Studio会根据向导指示,进入到SDK下载界面,**HarmonyOS SDK Location**选择本地解压的SDK包路径,然后点击**Next**。 >![](public_sys-resources/icon-note.gif) **说明:** - >如果不是首次安装DevEco Studio,可能无法查看进入该界面,可通过欢迎页的**Configure \> Settings \> Appearance & Behavior \> System Settings \> HarmonyOS SDK**界面,点击**HarmonyOS SDK Location**加载SDK。 + >如果不是首次安装DevEco Studio,可能无法查看进入该界面,可通过欢迎页的**Configure (或**![](figures/zh-cn_image_0000001117475774.png)**图标)\> Settings \> Appearance & Behavior \> System Settings \> HarmonyOS SDK**界面,点击**HarmonyOS SDK Location**加载SDK。 ![](figures/zh-cn_image_0000001117288684.png) @@ -76,32 +75,3 @@ DevEco Studio通过SDK Manager统一管理SDK及工具链,OpenHarmony包含如 ![](figures/zh-cn_image_0000001163170097.png) -## 导入工程 - -OpenHarmony SDK配置完成后,便可以启动应用开发。针对OpenHarmony应用开发,**只能通过导入Sample工程的方式来创建一个新工程**。 - -1. 在DevEco Studio的欢迎页,点击**Import HarmonyOS Sample**按钮,导入Sample工程。 - - ![](figures/zh-cn_image_0000001163495457.png) - -2. 选择ability下的**HelloWorld**工程,然后点击**Next**。 - - ![](figures/zh-cn_image_0000001117295732.png) - -3. 设置**App Name**和**Project Location**,然后点击**Finish**,等待Sample工程导入完成。 - - ![](figures/zh-cn_image_0000001163500855.png) - -4. Sample导入后,等待工程同步完成,此时工程会同步失败。请打开工程下的build.gradle,修改hap插件的版本号为“2.4.4.3-RC”。 - - ![](figures/zh-cn_image_0000001163550987.png) - -5. 修改完成后,点击右上角Gradle中的![](figures/zh-cn_image_0000001117304698.png)按钮,重新同步工程。 - - ![](figures/zh-cn_image_0000001117145200.png) - -6. 等待工程同步完成,同步成功后,便可以进行OpenHarmony应用开发了。 - - ![](figures/zh-cn_image_0000001117145614.png) - - diff --git "a/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony\345\272\224\347\224\250\347\255\276\345\220\215\344\277\241\346\201\257.md" "b/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony\345\272\224\347\224\250\347\255\276\345\220\215\344\277\241\346\201\257.md" index 94b50f2b6805a2b06d1c2061844420bb310894fa..3989191cb2886bee7613594d2a68e3d1da698b3b 100644 --- "a/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony\345\272\224\347\224\250\347\255\276\345\220\215\344\277\241\346\201\257.md" +++ "b/zh-cn/application-dev/quick-start/\351\205\215\347\275\256OpenHarmony\345\272\224\347\224\250\347\255\276\345\220\215\344\277\241\346\201\257.md" @@ -71,24 +71,21 @@ java -jar provisionsigtool.jar sign --in UnsgnedReleasedProfileTemplate.json --o 在真机设备上调试前,需要使用到制作的私钥(.p12)文件、证书(.cer)文件和Profile(.p7b)文件对调试的模块进行签名。 -打开**File \> Project Structure**,在**Modules\>entry(模块名称)\>Signing Configs \> debug**窗口中,配置指定模块的调试签名信息。 - ->![](public_sys-resources/icon-note.gif) **说明:** ->如果需要发布release类型的hap包,请将签名信息配置在**Modules\>entry(模块名称)\>Signing Configs \> release**中。 +打开**File \> Project Structure**,点击**Project \> Signing Configs \> debug**窗口中,去除勾选“Automatically generate signing”,然后配置指定模块的调试签名信息。 - **Store File**:选择密钥库文件,文件后缀为.p12,该文件为[生成密钥和证书请求文件](#section153146467405)中生成的.p12文件。 -- **Store Password**:输入密钥库密码。 -- **Key Alias**:输入密钥的别名信息。 -- **Key Password**:输入密钥的密码。 -- **SignAlg**:签名算法,固定为SHA256withECDSA。 +- **Store Password**:输入密钥库密码,该密码为[生成密钥和证书请求文件](#section153146467405)中填写的密钥库密码保持一致。 +- **Key Alias**:输入密钥的别名信息,与[生成密钥和证书请求文件](#section153146467405)中填写的别名保持一致。 +- **Key Password**:输入密钥的密码,与**Store Password**保持一致。 +- **Sign Alg**:签名算法,固定为SHA256withECDSA。 - **Profile File**:选择申请的调试Profile文件,文件后缀为.p7b。 - **Certpath File**:选择申请的调试数字证书文件,文件后缀为.cer。 -![](figures/zh-cn_image_0000001160327971.png) +![](figures/zh-cn_image_0000001117638220.png) -设置完签名信息后,点击**OK**进行保存,然后可以在模块下的build.gradle中查看签名的配置信息。 +设置完签名信息后,点击**OK**进行保存,然后可以在工程下的build.gradle中查看签名的配置信息。 -![](figures/zh-cn_image_0000001113648168.png) +![](figures/zh-cn_image_0000001117638526.png) 默认情况下,DevEco Studio编译hap包的类型为debug类型,如果需要编译release类型的hap包,请打开工程左下角的OhosBuild Variants,设置模块的编译构建类型为release。关于编译构建hap的详细说明请参考[HUAWEI DevEco Studio使用指南](https://developer.harmonyos.com/cn/docs/documentation/doc-guides/build_hap-0000001053342418)。 @@ -96,5 +93,5 @@ java -jar provisionsigtool.jar sign --in UnsgnedReleasedProfileTemplate.json --o 编译完成后,OpenHarmony应用的Hap包可以从工程的bulid目录下获取。 -![](figures/zh-cn_image_0000001163552429.png) +![](figures/zh-cn_image_0000001163918627.png) diff --git "a/zh-cn/device-dev/quick-start/Hi3516\345\274\200\345\217\221\346\235\277\344\273\213\347\273\215.md" "b/zh-cn/device-dev/quick-start/Hi3516\345\274\200\345\217\221\346\235\277\344\273\213\347\273\215.md" index 1aee6edce4206ed38a267c199fcea535a132e7b6..3c6ebbc875e4460fe0fb51105aae2fcd5571928a 100755 --- "a/zh-cn/device-dev/quick-start/Hi3516\345\274\200\345\217\221\346\235\277\344\273\213\347\273\215.md" +++ "b/zh-cn/device-dev/quick-start/Hi3516\345\274\200\345\217\221\346\235\277\344\273\213\347\273\215.md" @@ -5,7 +5,7 @@ ## 简介 -Hi3516DV300作为新一代行业专用Smart HD IP摄像机SOC,集成新一代ISP、H.265视频压缩编码器,同时集成高性能NNIE引擎,使得Hi3516DV300在低码率、高画质、智能处理和分析、低功耗等方面引领行业水平。 +Hi3516DV300作为新一代行业专用Smart HD IP摄像机SOC,集成新一代ISP\(Image Signal Processor\)、H.265视频压缩编码器,同时集成高性能NNIE引擎,使得Hi3516DV300在低码率、高画质、智能处理和分析、低功耗等方面引领行业水平。 **图 1** Hi3516单板正面外观图 diff --git "a/zh-cn/device-dev/quick-start/Ubuntu\347\274\226\350\257\221\347\216\257\345\242\203\345\207\206\345\244\207-9.md" "b/zh-cn/device-dev/quick-start/Ubuntu\347\274\226\350\257\221\347\216\257\345\242\203\345\207\206\345\244\207-9.md" index dcb5966296253c6e36f295ff895caf7ba198fce1..5f4d2d20e576b2626297c4bcd8f28307dca66357 100644 --- "a/zh-cn/device-dev/quick-start/Ubuntu\347\274\226\350\257\221\347\216\257\345\242\203\345\207\206\345\244\207-9.md" +++ "b/zh-cn/device-dev/quick-start/Ubuntu\347\274\226\350\257\221\347\216\257\345\242\203\345\207\206\345\244\207-9.md" @@ -5,8 +5,8 @@ - [Docker环境安装使用](#section22916211916) - [安装包方式准备Ubuntu编译环境](#section25961010189) - - [获取标准系统源码](#section15424183111912) - [安装依赖工具](#section109262032104819) + - [获取标准系统源码](#section6325556113718) - [获取prebuilts](#section16453104219209) - [配置NodeJS环境和获取Node\_modules依赖包](#section133741330192119) - [安装hc-gen工具](#section149281248182116) @@ -23,7 +23,7 @@ OpenHarmony标准系统为开发者提供的Docker环境已经将对应的编译 ### 获取系统源码 -具体获取方式请参考[获取标准系统设备源码](../get-code/源码获取.md)。 +具体获取方式请参考[获取标准系统源码](../get-code/源码获取.md)。 ### Docker环境安装使用 @@ -33,24 +33,27 @@ OpenHarmony标准系统为开发者提供的Docker环境已经将对应的编译 安装包方式具体操作分为如下几步: -1. 获取系统源码。 -2. 安装依赖工具。 +1. 安装依赖工具。 +2. 获取系统源码。 3. 获取prebuilts。 4. 配置NodeJS环境和获取Node\_modules依赖包。 5. 安装hc-gen工具。 -### 获取标准系统源码 - -具体获取方式请参考[获取标准系统设备源码](../get-code/源码获取.md)。 - ### 安装依赖工具 -安装命令: +安装命令如下: ``` sudo apt-get install binutils git-core git-lfs gnupg flex bison gperf build-essential zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev ccache libgl1-mesa-dev libxml2-utils xsltproc unzip m4 ``` +>![](public_sys-resources/icon-note.gif) **说明:** +>以上安装命令适用于Ubuntu18.04,其他版本请根据安装包名称采用对应的安装命令。 + +### 获取标准系统源码 + +具体获取方式请参考[获取标准系统源码](../get-code/源码获取.md)。 + ### 获取prebuilts 1. 切换到OpenHarmony工作目录。 @@ -82,7 +85,7 @@ sudo apt-get install binutils git-core git-lfs gnupg flex bison gperf build-esse ### 配置NodeJS环境和获取Node\_modules依赖包 -为了编译JS Framework,开发者需要在Linux服务器下载配置NodeJS,具体操作如下: +为了编译JS Framework,开发者需要在Linux服务器下载配置NodeJS(注意:步骤中OpenHarmony目录指代当前工程的根目录,可自定义),具体操作如下: 1. 开发者在Linux服务器下载Nodejs。 @@ -90,25 +93,20 @@ sudo apt-get install binutils git-core git-lfs gnupg flex bison gperf build-esse mkdir -p OpenHarmony/prebuilts/build-tools/common/nodejs #创建nodejs目录 cd OpenHarmony/prebuilts/build-tools/common/nodejs #进入nodejs目录 wget --no-check-certificate https://nodejs.org/download/release/v12.18.4/node-v12.18.4-linux-x64.tar.gz #下载nodejs + tar -zxvf node-v12.18.4-linux-x64.tar.gz #解压nodejs压缩包 + cd - #切换到之前的目录 ``` -2. 解压NodeJS配置NodeJS环境。 - - ``` - tar -zxvf node-v12.18.4-linux-x64.tar.gz #解压nodejs压缩包 - echo "export PATH=`pwd`/node-v12.18.4-linux-x64/bin:${PATH}" >> ~/.bashrc;source ~/.bashrc #设置NodeJS环境变量 - cd - #切换到之前的目录 - ``` - -3. 进入OpenHarmony代码的third\_party/jsframework目录,下载node\_modules包。 +2. 配置NodeJS环境变量,下载node\_modules包。 ``` cd OpenHarmony/third_party/jsframework #进入jsframework目录 + export PATH=../../prebuilts/build-tools/common/nodejs/node-v12.18.4-linux-x64/bin:${PATH} #设置NodeJS环境变量 npm install #下载node_modules包 cd - #切换到之前的目录 ``` -4. 把下载的node\_modules包放入OpenHarmony代码的prebuilts/build-tools/common/js-framework目录下。 +3. 把下载的node\_modules包放入OpenHarmony代码的prebuilts/build-tools/common/js-framework目录下。 ``` mkdir -p OpenHarmony/prebuilts/build-tools/common/js-framework #创建js-framework目录 diff --git "a/zh-cn/device-dev/quick-start/\345\274\200\345\217\221\346\255\245\351\252\244-11.md" "b/zh-cn/device-dev/quick-start/\345\274\200\345\217\221\346\255\245\351\252\244-11.md" index f5f9db54962e91131713490c95d06aeb50dca3d2..37b798d84329ebe4a92979fe92ceb5560645b6a5 100644 --- "a/zh-cn/device-dev/quick-start/\345\274\200\345\217\221\346\255\245\351\252\244-11.md" +++ "b/zh-cn/device-dev/quick-start/\345\274\200\345\217\221\346\255\245\351\252\244-11.md" @@ -17,7 +17,7 @@ ## 编译 -在Linux环境进行如下操作。 +使用Docker环境的开发者可参照Docker使用指导进行编译。采用安装包方式的开发者在Linux环境进行如下操作。 1. 进入源码根目录,执行如下命令进行版本编译。 @@ -213,7 +213,7 @@ Hi3516DV300开发板使用USB烧录方式,支持Windows系统。如果采用 - upload\_protocol:选择烧录协议,固定选择“hiburn-usb”。 - upload\_partitions:选择待烧录的文件,包括fastboot、boot、updater、misc、system、vendor和userdata。 - ![](figures/zh-cn_image_0000001163569081.png) + ![](figures/zh-cn_image_0000001160528243.png) 6. 所有的配置都修改完成后,在工程配置页签的顶部,点击**Save**进行保存。 7. 打开工程文件,点击![](figures/2021-01-27_170334-17.png)图标,打开DevEco Device Tool界面,在“PROJECT TASKS”中,点击fastboot下的**Erase**按钮,擦除U-Boot。