Complete installation package generation method and device, storage medium and electronic device

Through resource integration and rebuilding methods, a complete installation package is generated, which solves the problem of inefficiency caused by the need to upload and integrate a large number of har packages in the existing technology, and achieves fast and efficient installation package generation.

CN119806628APending Publication Date: 2025-04-11QINGDAO HAIER TECH +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411743309.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-29
Publication Date
2025-04-11

AI Technical Summary

Technical Problem

In the prior art, all har packages need to be uploaded and integrated into shell projects to generate a complete installation package, resulting in inefficient processing.

Method used

By obtaining multiple first resource packages built by the resource construction module, resource integration is carried out to generate a second resource package, and publishing it to the target system, and rebuilding the target project through the target system and the second resource package to generate a complete installation package.

Benefits of technology

It realizes the rapid generation of complete installation packages, reduces development workload, improves processing efficiency, and solves the problem of inefficient processing in the existing technology.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119806628A_ABST
    Figure CN119806628A_ABST
Patent Text Reader

Abstract

The invention discloses a complete installation package generation method and device, a storage medium and an electronic device, and relates to the technical field of smart home, and the complete installation package generation method comprises the steps: obtaining a plurality of first resource packages constructed by a resource construction module, and carrying out the resource integration of the plurality of first resource packages, and generating a second resource package; issuing the second resource packet to a target system; a target project is reconstructed through the target system and the second resource packet, so that a complete installation packet is generated in the target project according to the second resource packet, and the reconstruction of the target project is used for establishing an association relationship between the second resource packet and the target project; by adopting the scheme, the problem that in the related technology, a complete installation package can be generated only by uploading and integrating all haar packages into a shell project, and the processing efficiency is low is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of smart home technology, and more specifically, to a method and device for generating a complete installation package, a storage medium, and an electronic device. Background Art

[0002] The adaptation of the Hongmeng platform is a problem that many apps currently need to face. Using a fast platform solution during the adaptation process is a relatively resource-saving way, such as using the flutter solution.

[0003] Under this premise, how to build the Hongmeng Flutter business into a unified HAR on the Hongmeng platform is a rather troublesome problem. According to the solution provided by Hongmeng Flutter, the products built by Flutter are all separate HARs, not a single HAR. All HARs need to be merged into one before the Hongmeng shell project can reference it. Otherwise, all HAR packages need to be uploaded and integrated into the shell project, which is inconvenient for integration.

[0004] In the related technology, all har packages need to be uploaded and integrated into the shell project to generate a complete installation package, which has low processing efficiency and other problems, and no effective solution has been proposed yet. Summary of the invention

[0005] The embodiments of the present application provide a method and device for generating a complete installation package, a storage medium and an electronic device, so as to at least solve the problem in the prior art that all har packages need to be uploaded and integrated into a shell project to generate a complete installation package, resulting in low processing efficiency.

[0006] According to an embodiment of the present application, a method for generating a complete installation package is provided, including: obtaining multiple first resource packages constructed by a resource construction module, and integrating resources of the multiple first resource packages to generate a second resource package; publishing the second resource package to a target system; and reconstructing a target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein reconstructing the target project is used to establish an association relationship between the second resource package and the target project.

[0007] In an exemplary embodiment, before rebuilding the target project through the target system and the second resource package, the method also includes: identifying the dependency of the second resource package through the target system to obtain dependency information corresponding to the second resource package; and modifying the dependency configuration of the target project according to the dependency information.

[0008] In an exemplary embodiment, a target project is rebuilt through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, including: parsing the dependency configuration of the target project through the target system, integrating the third resource package indicated by the dependency configuration into the target project, wherein the third resource package includes the second resource package; code-linking a first code corresponding to the third resource package with a second code corresponding to the target project to establish a reference relationship between the target project and the third resource package; code-optimizing the third code corresponding to the target project, and generating the complete installation package according to the optimized third code and the third resource package, wherein the third code is the second code after code-linking.

[0009] In an exemplary embodiment, resources are integrated on the multiple first resource packages to generate a second resource package, including: decompressing the multiple first resource packages to obtain multiple decompressed first resource packages; deduplicating resource files included in the multiple decompressed first resource packages to obtain multiple processed first resource packages; and packaging the multiple processed first resource packages to generate the second resource package.

[0010] In an exemplary embodiment, after generating a complete installation package in the target project according to the second resource package, the method further includes: performing a performance test on the complete installation package according to a test case to obtain a performance test result; and optimizing the complete installation package according to the performance test result.

[0011] In an exemplary embodiment, before publishing the second resource package to the target system, the method further includes: performing version consistency verification on the multiple first resource packages and the second resource package; if the multiple first resource packages and the second resource package fail to pass the version consistency verification, prohibiting the second resource package from being published to the target system; if the multiple first resource packages and the second resource package pass the version consistency verification, publishing the second resource package to the target system.

[0012] According to another embodiment of the embodiment of the present application, a device for generating a complete installation package is also provided, including: a resource integration module, used to obtain multiple first resource packages constructed by a resource construction module, and integrate the resources of the multiple first resource packages to generate a second resource package; a publishing module, used to publish the second resource package to a target system; a generation module, used to reconstruct a target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein the reconstruction of the target project is used to establish an association relationship between the second resource package and the target project.

[0013] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned method for generating a complete installation package when running.

[0014] According to another aspect of an embodiment of the present application, an electronic device is also provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the method for generating a complete installation package through the computer program.

[0015] According to another aspect of the embodiments of the present application, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps of the method described in each embodiment of the present application are implemented.

[0016] In an embodiment of the present application, multiple first resource packages constructed by a resource construction module are first obtained, and resources of the multiple first resource packages are integrated to generate a second resource package; then the second resource package is published to a target system; the target project is reconstructed through the target system and the second resource package, so as to generate a complete installation package in the target project according to the second resource package, wherein the goal of reconstructing the target project is to establish an association relationship between the second resource package and the target project; adopting the above scheme, all har packages (multiple first resource packages) are first integrated into a whole package (second resource package), and then integrated into the shell project (target project), so as to quickly generate a complete installation package, reduce development workload, and improve processing efficiency; thereby solving the problem in the related art that all har packages need to be uploaded and integrated into the shell project to generate a complete installation package, resulting in low processing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0018] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0019] Figure 1 It is a hardware environment diagram of an optional method for generating a complete installation package according to an embodiment of the present application;

[0020] Figure 2is a flowchart of an optional method for generating a complete installation package according to an embodiment of the present application;

[0021] Figure 3 This is a process sequence diagram of an optional module construction method based on Hongmeng Flutter according to an embodiment of the present application;

[0022] Figure 4 It is a structural block diagram of an optional device for generating a complete installation package according to an embodiment of the present application. DETAILED DESCRIPTION

[0023] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present application.

[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0025] According to one aspect of an embodiment of the present application, a method for generating a complete installation package is provided. The method for generating a complete installation package is widely used in smart home (Smart Home), smart home, smart home device ecology, smart residential (Intelligence House) ecology and other whole-house intelligent digital control application scenarios. Optionally, in this embodiment, the above-mentioned method for generating a complete installation package can be applied to Figure 1 In the hardware environment composed of the terminal device 102 and the server 104 shown in FIG. Figure 1As shown, the server 104 is connected to the terminal device 102 via a network, and can be used to provide services (such as application services, etc.) for the terminal or a client installed on the terminal. A database can be set on the server or independently of the server to provide data storage services for the server 104. Cloud computing and / or edge computing services can be configured on the server or independently of the server to provide data computing services for the server 104.

[0026] The network may include but is not limited to at least one of the following: wired network, wireless network. The wired network may include but is not limited to at least one of the following: wide area network, metropolitan area network, local area network, and the wireless network may include but is not limited to at least one of the following: WIFI (Wireless Fidelity), Bluetooth. The terminal device 102 may be but is not limited to a PC, a mobile phone, a tablet computer, a smart air conditioner, a smart range hood, a refrigerator, a smart oven, a smart stove, a smart washing machine, a smart water heater, a smart washing equipment, a smart dishwasher, a smart projection equipment, a smart TV, a smart clothes drying rack, a smart curtain, a smart audio and video, a smart socket, a smart speaker, a smart fresh air equipment, a smart kitchen and bathroom equipment, a smart bathroom equipment, a smart sweeping robot, a smart window cleaning robot, a smart mopping robot, a smart air purification equipment, a smart steamer, a smart microwave oven, a smart kitchen treasure, a smart purifier, a smart water dispenser, a smart door lock, etc.

[0027] In this embodiment, a method for generating a complete installation package is provided. Figure 2 : is a flowchart of an optional method for generating a complete installation package according to an embodiment of the present application, the process comprising the following steps:

[0028] Step S202, obtaining a plurality of first resource packages constructed by a resource construction module, and integrating resources of the plurality of first resource packages to generate a second resource package;

[0029] It should be noted that the above resource building modules can be understood as Flutter modules. Flutter modules refer to code units that can be built and run independently in the Flutter framework. These units usually contain a set of user interfaces and business logic for specific functions. A Flutter module can be regarded as a subset of a Flutter project. It has its own pubspec.yaml file to manage dependencies and can be built independently of the main application.

[0030] In cross-platform development, Flutter modules are designed for reuse, which means they can be reused on different platforms (such as iOS, Android, or HarmonyOS) and in different main application projects without major modifications to the modules themselves. This modular development approach helps improve code maintainability and development efficiency, especially in scenarios where multiple platforms or multiple applications share the same functionality.

[0031] Step S204, publishing the second resource package to the target system;

[0032] Step S206, reconstructing the target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein reconstructing the target project is used to establish an association relationship between the second resource package and the target project.

[0033] In an embodiment of the present application, multiple first resource packages constructed by a resource construction module are first obtained, and resources of the multiple first resource packages are integrated to generate a second resource package; then the second resource package is published to a target system; the target project is reconstructed through the target system and the second resource package, so as to generate a complete installation package in the target project according to the second resource package, wherein the goal of reconstructing the target project is to establish an association relationship between the second resource package and the target project; adopting the above scheme, all har packages (multiple first resource packages) are first integrated into a whole package (second resource package), and then integrated into the shell project (target project), so as to quickly generate a complete installation package, reduce development workload, and improve processing efficiency; thereby solving the problem in the related art that all har packages need to be uploaded and integrated into the shell project to generate a complete installation package, resulting in low processing efficiency.

[0034] Optionally, execute the above step S206: before rebuilding the target project through the target system and the second resource package, the method also includes: identifying the dependencies of the second resource package through the target system to obtain dependency information corresponding to the second resource package; and modifying the dependency configuration of the target project according to the dependency information.

[0035] It is necessary to identify the dependencies of the second resource package in advance and obtain the dependency information corresponding to the second resource package; then modify the Hongmeng shell project (i.e. the above-mentioned target project) according to the dependency information to ensure that the shell project can recognize and use the above-mentioned integrated HAR package (i.e. the second resource package), thereby realizing the seamless integration of Flutter business and Hongmeng native development.

[0036] Optionally, the above-mentioned step S206: reconstructing the target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package can be achieved in the following ways, including: parsing the dependency configuration of the target project through the target system, integrating the third resource package indicated by the dependency configuration into the target project, wherein the third resource package includes the second resource package; code-linking the first code corresponding to the third resource package and the second code corresponding to the target project to establish a reference relationship between the target project and the third resource package; code-optimizing the third code corresponding to the target project, and generating the complete installation package according to the optimized third code and the third resource package, wherein the third code is the second code after code-linking.

[0037] The process of rebuilding the HarmonyOS shell project specifically includes the following processes: the build system (i.e., the target system) is responsible for parsing all dependencies in the shell project, including the original code dependencies and the har files generated from the flutter module. When the har files are integrated into a unified har package and correctly added to the dependency configuration of the shell project, the build system ensures that all necessary libraries and resources are included. The build system will then compile the original soundtrack in the shell project and process the precompiled code in the har package to ensure that they are compatible with the HarmonyOS operating system (Hongmeng system) and generate executable binary code (i.e., the third code); finally, the build system packages the original code, the code in the har package, and other resources of the application (such as pictures, audio, etc.) into a complete installation package, which contains all the components required to run the application.

[0038] Optionally, resources of the multiple first resource packages are integrated to generate a second resource package, including: decompressing the multiple first resource packages to obtain multiple decompressed first resource packages; deduplicating resource files included in the multiple decompressed first resource packages to obtain multiple processed first resource packages; and packaging the multiple processed first resource packages to generate the second resource package.

[0039] Optionally, in the embodiment of the present application, the integration of the HAR package can be completed by creating an integration script. Specifically, the integration script is mainly responsible for the following tasks: 1. Unzip the HAR file and use the decompression tool to unzip all HAR files into a temporary directory. 2. Check and merge voluntarily. In the decompressed file, check whether there are duplicate resource files (such as pictures, audio, etc.). If so, keep one version and update the corresponding reference path. For code files, it is also necessary to check whether there are conflicts, such as the same class name or function name. 3. Repackage the HAR file. Use a compression tool to repackage the integrated resources and code into a HAR file. When packaging, it is necessary to ensure that all necessary metadata (such as the configuration information of the HAR file) are correctly updated.

[0040] Based on the above steps, after generating a complete installation package in the target project according to the second resource package, the method further includes: performing a performance test on the complete installation package according to a test case to obtain a performance test result; and optimizing the complete installation package according to the performance test result.

[0041] After generating the complete installation package, it is crucial to conduct testing to ensure that the application can run stably, function correctly, meet performance requirements, and comply with security and user experience standards on the target platform. For Flutter applications based on the Hongmeng platform, the complete testing process may include the following steps:

[0042] 1. Prepare the test environment: ensure that the test equipment (including simulators), test tools and test data are ready;

[0043] 2. Execute test cases: Test the application functions and performance one by one according to the pre-prepared test cases;

[0044] 3. Record test results: Record the problems encountered during the test in detail, including error messages, reproduction steps, screenshots, etc.;

[0045] 4. Problem repair and retesting: For problems found during testing, the development team needs to repair them and test again to verify the effectiveness of the repairs;

[0046] 5. Performance optimization: Based on the performance test results, optimize the code and resources to ensure the application operation process.

[0047] In the embodiment of the present application, only one performance test process is shown. In actual application, other tests need to be performed on the complete installation package, such as functional testing, compatibility testing and other different types of tests, to ensure the availability of the complete installation package in all aspects.

[0048] The following is an introduction to the different categories of tests:

[0049] 1. Functional testing: Verify that all functions of the application work as expected, which includes checking whether the user interface, interaction logic, business functions, etc. are normal. Functional testing can be performed on simulators and real devices to cover different environments.

[0050] 2. Compatibility testing: Test the performance of the app on different versions of HarmonyOS, different devices, and different screen sizes. Ensure that the app can adapt to various operating environments and has no layout or performance issues.

[0051] 3. Performance testing: Evaluate the performance indicators of the application, such as startup time, response speed, memory usage, CPU usage, etc. Use performance testing tools, such as the performance analysis tool in DevEco Studio, to monitor and optimize these indicators.

[0052] 4. Stability test: Run the application for a long time to test its stability under continuous use, including frequent switching applications, restarting after a long period of standby, etc., to check for problems such as crashes, data loss or memory leaks.

[0053] 5. Security testing: Ensure that the application complies with the security specifications of the Hongmeng platform, such as permission management, data encryption, network communication security, etc. Use the security testing tools or services provided by the Hongmeng platform for testing.

[0054] 6. Distributed capability testing: If the application uses Hongmeng's distributed capabilities, such as distributed data management, cross-device collaboration, etc., it is necessary to specifically test the correctness and stability of these functions. This may require setting up multiple devices to simulate different network environments and device states.

[0055] Optionally, before publishing the second resource package to the target system, the method further includes: performing version consistency verification on the multiple first resource packages and the second resource package; if the multiple first resource packages and the second resource package fail to pass the version consistency verification, prohibiting the second resource package from being published to the target system; if the multiple first resource packages and the second resource package pass the version consistency verification, publishing the second resource package to the target system.

[0056] Optionally, version control is required before releasing the HAR package to ensure that the version of the HAR package is consistent with the version of the final complete installation package; therefore, the versions of the first resource package and the second resource package need to be verified first to ensure that the version of the final generated complete installation package is correct.

[0057] In an optional embodiment, the present application proposes a module construction method and app development solution based on Hongmeng Flutter. The overall process is as follows: Figure 3 As shown, the specific steps include:

[0058] 1. Complete the dependency synchronization of the flutter module through the Hongmeng flutter command;

[0059] 2. Build products related to Hongmeng HAR;

[0060] 3. Copy the Hongmeng har product directory to the Hongmeng project;

[0061] 4. Modify the dependency configuration of the Hongmeng project;

[0062] 5. Build the Hongmeng project through the native build command of Hongmeng next, and regenerate the Hongmeng next build product, which is the har package that the shell project ultimately depends on;

[0063] 6. Publish the har package to the Hongmeng private library;

[0064] 7. Publish the har package of flutter and module that the shell project of Hongmeng Next depends on to the build system;

[0065] 8. Build the whole package (i.e. complete installation package).

[0066] Through the above embodiments, the flutter product har supporting the Hongmeng platform is constructed through the flutter of the Hongmeng platform for use in the construction of the Hongmeng installation package. The embodiment of this application proposes an integrated construction solution for flutter products, merging the many construction products of Hongmeng flutter into a har package, proposing a har package construction and merging solution for Hongmeng flutter, and at the same time proposing a Hongmeng app construction and development solution based on Hongmeng flutter. Through this solution, the flutter business previously developed on the Android and IOS platforms can be reused and directly ported to the Hongmeng platform, saving development workload and improving development efficiency.

[0067] Through the description of the above implementation methods, those skilled in the art can clearly understand that the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods of each embodiment of the present application.

[0068] In the present embodiment, a device for generating a complete installation package is also provided, and the device for generating the complete installation package is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions thereof will not be repeated. As used below, the term "module" may be a combination of software and / or hardware that implements a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and contemplated.

[0069] Figure 4 is a structural block diagram of an optional device for generating a complete installation package according to an embodiment of the present application; Figure 4 As shown, including:

[0070] The resource integration module 42 is used to obtain a plurality of first resource packages constructed by the resource construction module, and integrate the plurality of first resource packages to generate a second resource package;

[0071] A publishing module 44, used for publishing the second resource package to a target system;

[0072] The generation module 46 is used to reconstruct the target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein the reconstruction of the target project is used to establish an association relationship between the second resource package and the target project.

[0073] Through the above-mentioned device, firstly obtain multiple first resource packages constructed by the resource construction module, and integrate the resources of the multiple first resource packages to generate a second resource package; then publish the second resource package to the target system; reconstruct the target project through the target system and the second resource package, so as to generate a complete installation package in the target project according to the second resource package, wherein the purpose of reconstructing the target project is to establish an association relationship between the second resource package and the target project; adopting the above-mentioned scheme, first integrate all HAR packages (multiple first resource packages) into a whole package (second resource package), and then integrate it into the shell project (target project), so as to quickly generate a complete installation package, reduce the development workload, and improve the processing efficiency; thereby solving the problem in the related technology that all HAR packages need to be uploaded and integrated into the shell project to generate a complete installation package, and the processing efficiency is low.

[0074] Optionally, the generating module 46 is further configured to identify the dependency of the second resource package through the target system, obtain dependency information corresponding to the second resource package, and modify the dependency configuration of the target project according to the dependency information.

[0075] It is necessary to identify the dependencies of the second resource package in advance and obtain the dependency information corresponding to the second resource package; then modify the Hongmeng shell project (i.e. the above-mentioned target project) according to the dependency information to ensure that the shell project can recognize and use the above-mentioned integrated HAR package (i.e. the second resource package), thereby realizing the seamless integration of Flutter business and Hongmeng native development.

[0076] Optionally, the above-mentioned generation module 46 is also used to parse the dependency configuration of the target project through the target system, integrate the third resource package indicated by the dependency configuration into the target project, wherein the third resource package includes the second resource package; code-link the first code corresponding to the third resource package with the second code corresponding to the target project, and establish a reference relationship between the target project and the third resource package; optimize the third code corresponding to the target project, and generate the complete installation package based on the optimized third code and the third resource package, wherein the third code is the second code after code-linking.

[0077] The process of rebuilding the HarmonyOS shell project specifically includes the following processes: the build system (i.e., the target system) is responsible for parsing all dependencies in the shell project, including the original code dependencies and the har files generated from the flutter module. When the har files are integrated into a unified har package and correctly added to the dependency configuration of the shell project, the build system ensures that all necessary libraries and resources are included. The build system will then compile the original soundtrack in the shell project and process the precompiled code in the har package to ensure that they are compatible with the HarmonyOS operating system (Hongmeng system) and generate executable binary code (i.e., the third code); finally, the build system packages the original code, the code in the har package, and other resources of the application (such as pictures, audio, etc.) into a complete installation package, which contains all the components required to run the application.

[0078] Optionally, the resource integration module 42 is further used to decompress the multiple first resource packages to obtain multiple decompressed first resource packages; deduplicate the resource files contained in the multiple decompressed first resource packages to obtain multiple processed first resource packages; and package the multiple processed first resource packages to generate the second resource package.

[0079] Optionally, in the embodiment of the present application, the integration of the HAR package can be completed by creating an integration script. Specifically, the integration script is mainly responsible for the following tasks: 1. Unzip the HAR file and use the decompression tool to unzip all HAR files into a temporary directory. 2. Check and merge voluntarily. In the decompressed file, check whether there are duplicate resource files (such as pictures, audio, etc.). If so, keep one version and update the corresponding reference path. For code files, it is also necessary to check whether there are conflicts, such as the same class name or function name. 3. Repackage the HAR file. Use a compression tool to repackage the integrated resources and code into a HAR file. When packaging, it is necessary to ensure that all necessary metadata (such as the configuration information of the HAR file) are correctly updated.

[0080] Optionally, the generating module 46 is further configured to perform a performance test on the complete installation package according to a test case to obtain a performance test result; and optimize the complete installation package according to the performance test result.

[0081] After generating the complete installation package, it is crucial to conduct testing to ensure that the application can run stably, function correctly, meet performance requirements, and comply with security and user experience standards on the target platform. For Flutter applications based on the Hongmeng platform, the complete testing process may include the following steps:

[0082] 1. Prepare the test environment: ensure that the test equipment (including simulators), test tools and test data are ready;

[0083] 2. Execute test cases: Test the application functions and performance one by one according to the pre-prepared test cases;

[0084] 3. Record test results: Record the problems encountered during the test in detail, including error messages, reproduction steps, screenshots, etc.;

[0085] 4. Problem repair and retesting: For problems found during testing, the development team needs to repair them and test again to verify the effectiveness of the repairs;

[0086] 5. Performance optimization: Based on the performance test results, optimize the code and resources to ensure the application operation process.

[0087] Optionally, the publishing module 44 is further used to perform version consistency verification on the multiple first resource packages and the second resource package; if the multiple first resource packages and the second resource package fail to pass the version consistency verification, the second resource package is prohibited from being published to the target system; if the multiple first resource packages and the second resource package pass the version consistency verification, the second resource package is published to the target system.

[0088] Optionally, version control is required before releasing the HAR package to ensure that the version of the HAR package is consistent with the version of the final complete installation package; therefore, the versions of the first resource package and the second resource package need to be verified first to ensure that the version of the final generated complete installation package is correct.

[0089] An embodiment of the present application further provides a storage medium, which includes a stored program, wherein the program executes any of the above methods when it is run.

[0090] Optionally, in this embodiment, the storage medium may be configured to store program codes for executing the following steps:

[0091] S1, obtaining a plurality of first resource packages constructed by a resource construction module, and integrating resources of the plurality of first resource packages to generate a second resource package;

[0092] S2, publishing the second resource package to the target system;

[0093] S3, reconstructing the target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein the reconstruction of the target project is used to establish an association relationship between the second resource package and the target project.

[0094] Optionally, in this embodiment, the above-mentioned storage medium may include but is not limited to: a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk or an optical disk, and other media that can store program codes.

[0095] An embodiment of the present application further provides an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to run the computer program to execute the steps in any one of the above method embodiments.

[0096] Optionally, in this embodiment, the processor may be configured to perform the following steps through a computer program:

[0097] S1, obtaining a plurality of first resource packages constructed by a resource construction module, and integrating resources of the plurality of first resource packages to generate a second resource package;

[0098] S2, publishing the second resource package to the target system;

[0099] S3, reconstructing the target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein the reconstruction of the target project is used to establish an association relationship between the second resource package and the target project.

[0100] Optionally, the electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the processor, and the input / output device is connected to the processor.

[0101] An embodiment of the present application further provides a computer program product, comprising a non-volatile computer-readable storage medium, wherein the non-volatile computer-readable storage medium stores a computer program product, and when the computer program is executed by a processor, the steps of the method described in each embodiment of the present application are implemented.

[0102] Optionally, in this embodiment, the above computer program may be configured to implement the following steps when executed by a processor:

[0103] S1, obtaining a plurality of first resource packages constructed by a resource construction module, and integrating resources of the plurality of first resource packages to generate a second resource package;

[0104] S2, publishing the second resource package to the target system;

[0105] S3, reconstructing the target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein the reconstruction of the target project is used to establish an association relationship between the second resource package and the target project.

[0106] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments and optional implementation modes, and this embodiment will not be described in detail here.

[0107] Obviously, those skilled in the art should understand that the above modules or steps of the present application can be implemented by a general computing device, they can be concentrated on a single computing device, or distributed on a network composed of multiple computing devices, and optionally, they can be implemented by a program code executable by a computing device, so that they can be stored in a storage device and executed by the computing device, and in some cases, the steps shown or described can be executed in a different order from that herein, or they can be made into individual integrated circuit modules, or multiple modules or steps therein can be made into a single integrated circuit module for implementation. Thus, the present application is not limited to any specific combination of hardware and software.

[0108] The above description is only the preferred embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the principles of the present application shall be included in the protection scope of the present application.

Claims

1. A method for generating a complete installation package, characterized in that: include: Acquire multiple first resource packages constructed by the resource construction module, and integrate the multiple first resource packages to generate a second resource package; Publishing the second resource package to the target system; The target project is reconstructed through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein the reconstruction of the target project is used to establish an association relationship between the second resource package and the target project.

2. The method for generating a complete installation package according to claim 1, characterized in that: Before reconstructing the target project by using the target system and the second resource package, the method further includes: Performing dependency identification on the second resource package through the target system to obtain dependency information corresponding to the second resource package; Modify the dependency configuration of the target project according to the dependency information.

3. The method for generating a complete installation package according to claim 2, characterized in that: Rebuilding the target project by using the target system and the second resource package to generate a complete installation package in the target project according to the second resource package includes: Parsing the dependency configuration of the target project through the target system, and integrating the third resource package indicated by the dependency configuration into the target project, wherein the third resource package includes the second resource package; Performing code linking on the first code corresponding to the third resource package and the second code corresponding to the target project, so as to establish a reference relationship between the target project and the third resource package; The third code corresponding to the target project is optimized, and the complete installation package is generated according to the optimized third code and the third resource package, wherein the third code is the second code after code linking.

4. The method for generating a complete installation package according to claim 1, characterized in that: Integrating the multiple first resource packages to generate a second resource package includes: Decompressing the multiple first resource packages to obtain multiple decompressed first resource packages; Deduplication processing is performed on the resource files included in the decompressed multiple first resource packages to obtain multiple processed first resource packages; The processed multiple first resource packages are packaged to generate the second resource package.

5. The method for generating a complete installation package according to claim 1, characterized in that: After generating a complete installation package in the target project according to the second resource package, the method further includes: Performing a performance test on the complete installation package according to the test case to obtain a performance test result; The complete installation package is optimized according to the performance test results.

6. The method for generating a complete installation package according to claim 1, characterized in that: Before publishing the second resource package to the target system, the method further includes: Performing version consistency check on the multiple first resource packages and the second resource package; If the plurality of first resource packages and the second resource package fail to pass the version consistency check, prohibiting the second resource package from being published to the target system; When the plurality of first resource packages and the second resource package pass the version consistency check, the second resource package is published to the target system.

7. A device for generating a complete installation package, characterized in that: include: A resource integration module, used to obtain a plurality of first resource packages constructed by the resource construction module, and integrate the plurality of first resource packages to generate a second resource package; A publishing module, used for publishing the second resource package to a target system; A generation module is used to reconstruct the target project through the target system and the second resource package to generate a complete installation package in the target project according to the second resource package, wherein the reconstruction of the target project is used to establish an association relationship between the second resource package and the target project.

8. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein the program executes the method described in any one of claims 1 to 6 when executed.

9. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 6 through the computer program.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.