Management method and device of universal package manager, medium and program product
By using compressed packages to manage software code and its dependencies between software development and the cloud, it solves the problem of existing package managers being unable to manage arbitrary programming languages and data formats, achieving a more universal package management solution and improving efficiency. Software development efficiency.
Patent Information
- Application Number
- CN202410859386.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-28
- Publication Date
- 2024-10-11
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing package managers have specificities and limitations and are unable to manage software packages in any programming language and data format, resulting in limitations for software developers in their use.
Provide a universal package manager management method, upload and download software code and its dependencies in the form of compressed packages, and use cloud storage and retrieval services to achieve software package management for any programming language and data format, including module configuration and compilation , compression, decompression and version update processes.
It makes the package manager more versatile, broadens the management capabilities of software packages in different programming languages and data formats, reduces the duplication of work and time expenditure of software developers, and solves the specificity and limitations of existing package managers.
Smart Images

Figure CN118760463A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of software development, and in particular to a management method of a universal package manager and its device, medium and program product. Background Art
[0002] During the software development process, software developers usually use mature code modules developed by others to build their software modules, which greatly speeds up the software development cycle. However, since some code modules require complex environment configuration and compilation optimization to make the selected code modules work properly, it takes up a lot of time and energy of software developers and leads to more duplication of work. Based on this, package managers came into being. The more mature package managers on the market include maven, pip, npm, etc. These package managers all have their own specificity and limitations, and cannot manage software packages in any programming language and data format, causing software developers to be very limited when using them. The present invention will provide a management method and device, medium and program product of a general package manager to achieve the ability to manage software packages in any type of programming language and data format, so that the package manager is more universal, thereby solving the problems of the specificity and limitations of existing package managers and the inability to manage software packages in any programming language and data format. Summary of the invention
[0003] In view of the above-mentioned shortcomings of the prior art, the purpose of the present application is to provide a general package manager management method and its device, medium and program product, so as to solve the above-mentioned problems.
[0004] To achieve the above-mentioned purpose and other related purposes, the first aspect of the present application provides a management method of a universal package manager, which is applied to a software development client, and the method includes: in response to a module configuration instruction, receiving an input module configuration code; the module configuration code includes: a compressed package name and a compressed package download path; in response to an execution download instruction, parsing the compressed package name and the compressed package download path in the module configuration code, and sending the parsed compressed package name to the cloud; receiving a compressed package downloaded from the cloud with the same name as the parsed compressed package name, and storing it in the parsed compressed package download path; the generation process of the compressed package sent by the cloud includes: the cloud receives the compressed package sent by the module development client in response to a module code submission instruction; the generation process of the compressed package sent by the module development client includes: the module development client receives the input module code in response to a module code input instruction, and compiles the input module code and its dependencies that need to be compiled, and compresses the compiled product and other dependencies that do not need to be compiled into a compressed package and sends it to the cloud; the dependency refers to the resources required to maintain the normal operation of the received module code when the software development client executes the received module code.
[0005] In some embodiments of the first aspect of the present application, the components of the compressed package name include: a module name and a version number.
[0006] In some embodiments of the first aspect of the present application, the module configuration instruction is automatically triggered by the Gitlab server in response to a module code submission command.
[0007] In some embodiments of the first aspect of the present application, it also includes: decompressing the compressed package stored in the parsed compressed package download path; and storing the decompressed product in the local code repository of the software development client.
[0008] In some embodiments of the first aspect of the present application, it also includes: responding to a module version update instruction, receiving an input compressed package name and a download path to be updated, sending a version update instruction and the compressed package name to be updated to the cloud; receiving a new version compressed package sent by the cloud and storing it in the input download path.
[0009] To achieve the above-mentioned purpose and other related purposes, the second aspect of the present application provides a management method of a universal package manager, which is applied to the cloud, and the method includes: in response to a module code submission instruction, receiving a compressed package sent by a module development client; the generation process of the compressed package sent by the module development client includes: the module development client receives the input module code in response to the module code input instruction, and compiles the input module code and its dependencies that need to be compiled, and compresses the compiled product and other dependencies that do not need to be compiled into a compressed package; the dependency refers to the resources required for maintaining the normal operation of the received module code when the software development client executes the received module code; in response to an execution download instruction, receiving a compressed package name from the software development client, retrieving and matching a stored compressed package with the same compressed package name, and sending the compressed package to the software development client; the generation process of the compressed package name includes: in response to a module configuration instruction, receiving the input module configuration code; the module configuration code includes: a compressed package name and a compressed package download path; in response to the execution download instruction, parsing the compressed package name in the module configuration code.
[0010] In some embodiments of the second aspect of the present application, it also includes: receiving a version update instruction and a compressed package name to be updated sent by a software development client, retrieving and matching a new version compressed package stored in the cloud that is identical to the compressed package name except for the version number, and sending the new version compressed package to the software development client.
[0011] To achieve the above-mentioned purpose and other related purposes, the third aspect of the present application provides a computer device, including a memory, a processor and a computer program stored in the memory; the processor executes the computer program to implement the method.
[0012] To achieve the above-mentioned purpose and other related purposes, the fourth aspect of the present application provides a computer-readable storage medium having a computer program stored thereon, and the computer program implements the method when executed by a processor.
[0013] To achieve the above-mentioned purpose and other related purposes, the fifth aspect of the present application provides a computer program product, which includes a computer program code. When the computer program code runs on a computer, the computer implements the method.
[0014] As described above, the present application has the following beneficial effects: the present invention provides a management method of a package manager for managing software packages in the form of compressed packages, and its device, medium and program product, by uploading the software code developed by the module developers to the cloud in the form of compressed packages, and providing the software developers with a download method in the form of compressed packages, so that the software packages in various programming languages and data formats developed by the module developers can be uploaded and downloaded in the form of compressed packages, so as to achieve the ability to manage software packages in any type of programming languages and data formats, making the package manager more universal, thereby greatly broadening the limitations of the original package manager in managing software packages in different programming languages and data formats, and solving the problems of the specificity and limitations of the existing package managers and the inability to manage software packages in any programming languages and data formats. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 Shown is a flowchart of a general package manager management method (applied to software development end) in one embodiment of the present application.
[0016] Figure 2 Shown is a flowchart of a general package manager management method (applied to software development end) in one embodiment of the present application.
[0017] Figure 3 Shown is a flowchart of a general package manager management method (applied to software development end) in one embodiment of the present application.
[0018] Figure 4 Shown is a flowchart of a management method (applied in the cloud) of a general package manager in one embodiment of the present application.
[0019] Figure 5 Shown is a flowchart of a management method (applied in the cloud) of a general package manager in one embodiment of the present application.
[0020] Figure 6 Shown is a schematic diagram of the overall flow of a management method of a general package manager in one embodiment of the present application.
[0021] Figure 7 Shown is a structural schematic diagram of a management electronic terminal of a universal package manager in one embodiment of the present application. DETAILED DESCRIPTION
[0022] The following describes the embodiments of the present application through specific examples, and those skilled in the art can easily understand other advantages and effects of the present application from the contents disclosed in this specification. The present application can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present application. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.
[0023] To facilitate understanding of the embodiments of the present application, first Figure 1-3 Detailed description. Figure 1 As shown, the management method of the general package manager applied to the software development client 1 in this embodiment mainly includes the following steps:
[0024] Step S101: In response to a module configuration instruction, receiving an input module configuration code; the module configuration code includes: a compressed package name and a compressed package download path.
[0025] The interactive modules involved in this application include: cloud side 2, software development client 1 and module development client 3. Cloud side 2 refers to the server side in cloud computing or the service side of a cloud service provider. In the package management method provided in this application, cloud side 2 can provide services such as storage and retrieval of compressed packages, and the services of cloud side 2 can be accessed through the network to provide software development client 1 and module development client 3 with upload and download services of compressed package resources. Software development client 1, i.e., the developer side, generally refers to the environment in which programmers write, debug and test software codes on their local computers. In the package manager management method provided in this application, software development client 1 provides software developers with services such as searching, downloading and decompressing module codes and their dependencies in the form of compressed packages. Module development client 3 refers to the environment used by module code developers to write module codes on their local computers. It is used in the package management provided in this application. Module development client 3 provides module developers with services such as module code compilation, compression and upload.
[0026] During the process of developing software, if software developers need to download code modules with specific functions on cloud 2, they can retrieve the compressed package resources in cloud 2 by entering corresponding keywords on cloud 2 to retrieve compressed packages that meet the specific functions. After retrieving the required compressed package, remember the name of the compressed package and edit the corresponding module configuration script file in the software development client 1, and configure the aforementioned compressed package name and the download path of the compressed package in the file.
[0027] Generally, the module configuration script file can be written as a JSON file. JSON files have the characteristics of strong readability, convenient data exchange, lightweight and easy to parse, and can provide users with a more concise module configuration method (i.e., the required compressed package file download method). Strong readability means that JSON adopts a concise and easy-to-understand text format, making it easy for humans to read and write, which is conducive to the readability and maintenance of data; convenient data exchange means that JSON is commonly used for network transmission and data exchange, and can easily exchange data between different platforms and systems, ensuring the portability and interoperability of data; lightweight means that compared with other data exchange formats such as XML, JSON has a lighter feature, because JSON uses Unicode encoding and concise data structure, which is suitable for reducing the size of data packets during network transmission and improving transmission efficiency; easy to parse means that the JSON data structure is clear and easy to parse and process. There are class libraries and tools that support JSON parsing in different programming languages. It should be understood that in addition to JSON files, in order to implement the management method of the package manager of the present invention, other types of file editing module configuration scripts can also be used, and this embodiment does not constitute a restriction on the writing language and file data format of the module configuration script file.
[0028] Exemplarily, the module configuration script file in JSON format can implement the compressed package name and download path and configuration through the following code. The resource server address configuration and download resource root path configuration involved in the code, as well as the module name, module version, compilation version number, platform architecture, etc. will be discussed in detail later:
[0029]
[0030]
[0031] Step S102: responding to executing the download instruction.
[0032] Step S103: parsing the compressed package name and compressed package download path in the module configuration code.
[0033] Step S104: Send the parsed compressed package name to the cloud 2.
[0034] Step S105: receiving a compressed package downloaded from the cloud 2 and having the same name as the parsed compressed package name.
[0035] Step S106: store it in the parsed compressed package download path.
[0036] In the management method of the package manager described in the present application, the compressed package download request proposed by the software development client 1 and the compressed package resources stored in the cloud 2 are matched by the compressed package name. Specifically, when the software developer has a code module download demand, he can first perform a keyword search in the cloud 2. After retrieving the required compressed package resources, according to the name of the compressed package resources, configure the compressed package with the same name in the module configuration script. After receiving the module configuration script, the cloud 2 uses the compressed package name in the configuration to search for the compressed package name in the stored compressed packages again. After retrieving the compressed package with the same name, the compressed package download resource is provided to the software development client 1, and the compressed package resource is downloaded to the corresponding location of the software development client 1 according to the download path configured in the module configuration script.
[0037] The resource download service provided by the cloud 2 can be realized by building a standard HTTP resource service. After the construction is completed, the download resources can be opened, so that the user of the software development client can access the compressed package resources in the cloud through the network and download them to the local device of the software development client. In the module configuration script file in the above JSON format, the code "url": "http: / / devres.handcake.net" is the address of the configured resource server.
[0038] Among them, Figure 2 As shown, the generation process of the compressed package sent by the cloud 2 includes:
[0039] Step S201: the cloud 2 receives the compressed package sent by the module development client 3 in response to the module code submission instruction.
[0040] The compressed package resources stored in the cloud 2 come from the module code uploaded by the module developer on the module development end. When the module developer writes and submits the module code in the package manager, the package manager will send the module code to the cloud 2. However, it is worth noting that the management method of the package manager provided in the present application uploads, stores and downloads the corresponding module code and its required dependencies in the form of compressed packages. Because module codes written in various programming languages and module codes and their dependencies in various data forms can be compressed into compressed package files, this method of processing, uploading, storing and downloading module codes through compressed packages greatly expands the types of manageable module codes, thereby realizing universal management of module codes of various data types and programming languages.
[0041] The generation process of the compressed package stored in the cloud 2 is as follows: Figure 3 As shown, including:
[0042] Step S301: the module development client 3 receives the input module code in response to the module code input instruction.
[0043] Step S302: Compile the input module code and its dependencies that need to be compiled.
[0044] Step S303: compress the compiled product and other dependencies that do not need to be compiled into a compressed package and send it to the cloud 2.
[0045] In software development, dependencies refer to external libraries, modules or components that are relied on in a project or code. When a software project needs to reference, call or use certain functions provided by the outside, it is necessary to explicitly declare its dependencies in the project. Software dependencies may include, but are not limited to: libraries or frameworks, modules, components and tools. Libraries or frameworks include jQuery, React, Spring, etc., which provide various common and complex functions. Developers can speed up the development process by introducing these libraries or frameworks. Modules refer to the modular development method often used in software development, which splits functions into independent modules. A project may rely on modules developed by other projects or teams to implement specific functions by introducing these modules. Components refer to independent units in software development, usually with specific functions or features. Developers may introduce third-party components (such as UI components, report components, etc.) to add specific functions to the project. Tools refer to the various tools (such as build tools, debugging tools, testing tools, etc.) that developers may use during the software development process. In this application, the dependencies mainly refer to all resources required to maintain the normal operation of the received module code when the software development client 1 executes the received module code.
[0046] In some embodiments of the first aspect of the present application, the components of the compressed package name include: a module name and a version number.
[0047] It should be understood that, in addition to the module name and version number, the compressed package name can also be composed of one or more of the platform, architecture, special mark bit, compiled version and suffix. And these components listed in this embodiment only provide a feasible way to name the compressed package, and do not constitute a restriction on the components of the compressed package name of this application. The module name, such as sl-control-file; the version number, such as 1.0.0, if it is an open source library, the actual version number of the open source library shall prevail; the platform, that is, the system operating platform applicable to the module, such as the windows platform, linux platform, etc.; the architecture, that is, the CPU architecture used by the module, such as amd64 architecture, x86_64 architecture, aarch64 architecture, etc.; the special mark bit, that is, the module’s customized special mark symbol, can be defaulted, such as GLIBC_2.31 mark symbol, CUSTOM_FIX mark symbol, etc.; the compiled version, that is, the current module compiled version number, can be incremented by 1 by default, or can be git’s COMMIT ID, which meets the basic requirements; the suffix can usually be set to ".zip".
[0048] In some embodiments of the first aspect of the present application, the module configuration instruction is automatically triggered by the Gitlab server in response to a module code submission command.
[0049] Specifically, when a module developer submits a new module code to the Gitlab server, the module configuration instructions can be automatically triggered by configuring Gitlab's Webhook. When configuring Webhook, you should first create a new Webhook and fill in the target address for receiving configuration instructions in the Webhook URL. The address can be a server application built by yourself or a service provided by a service provider. Secondly, you should configure Gitlab Webhook. In the Webhook configuration, select the appropriate trigger condition, such as triggering when submitting code, and then configure the corresponding Payload, which generally includes the submitted code information and COMMIT ID, etc. Then you need to build a Web server application to receive the request sent by Gitlab Webhook, write logic in the application, parse the received request, extract the submitted code information, and generate module configuration instructions as needed. Finally, configure the module automatic trigger, that is, to generate the module configuration instructions in the server application, and send the generated instructions to the appropriate target, thereby triggering the module development client 3 to configure the module.
[0050] It should be understood that Payload is a term widely used in the computer field, which means the actual data or effective load carried in data communication or transmission. In this application, "Payload" refers to the data content contained in the request sent by Gitlab Webhook, which usually appears in JSON format. "Payload" contains important data such as submitted code information, COMMITID, branch information, etc.
[0051] It should be understood that the COMMIT ID is a hash value used to uniquely identify each commit in the Git version control system. Each time a commit operation is performed, Git will calculate and generate a unique COMMIT ID based on the meta-information such as the commit content, author, and timestamp through a hash function (usually the SHA-1 algorithm). The Git is a distributed version control system developed by Linus Torvalds. Git is designed to help developers collaborate and manage code, making it easier for version control, collaborative development, and code management. It is widely used in software development projects, including personal projects and enterprise-level projects.
[0052] In some embodiments of the first aspect of the present application, it also includes: decompressing the compressed package stored in the parsed compressed package download path; and storing the decompressed product in the local code repository of the software development client 1.
[0053] The decompressed product is stored in the local code repository of the software development client 1. In this stage, the compressed package name should include the compilation version number, which needs to be dynamically generated. If it is managed by git, COMMIT ID is generally used for marking.
[0054] It should be understood that the dynamic generation mechanism is controlled by the user, and can be a counting and accumulation method or other methods. Generally speaking, if a company uses Gitlab to manage the code repository, then each time a developer submits code, a unique ID (COMMIT ID) of the submission record will be generated, and this ID can be used to identify the compiled version number.
[0055] In some embodiments of the first aspect of the present application, it also includes: responding to a module version update instruction, receiving an input compressed package name and a download path to be updated, sending a version update instruction and the compressed package name to be updated to the cloud 2; receiving a new version compressed package sent by the cloud 2 and storing it in the input download path.
[0056] To determine whether the compressed package of the software development client 1 needs to be updated, it is necessary to compare the compressed package name of the locally existing code with the compressed package name of the code module to be updated. If the two differ only in the version number, and the other parts of the compressed package name are the same, and the version number in the compressed package name of the code module to be updated on the cloud is newer than the version number of the aforementioned local compressed package, then an update is performed, and the higher-version compressed package on the cloud is downloaded to the software development client to replace the compressed package originally stored locally; otherwise, no update is required.
[0057] like Figure 4-5 As shown, in order to achieve the above-mentioned purpose and other related purposes, the second aspect of the present application provides a general package manager management method, which is applied to the cloud 2, and the steps of the method include:
[0058] Step S401: In response to the module code submission instruction, receiving the compressed package sent by the module development client 3;
[0059] Step S402: In response to executing the download instruction, receiving the compressed package name from the software development client 1;
[0060] Step S403: Retrieve and match a stored compressed package with the same name as the compressed package;
[0061] Step S404: sending the compressed package to the software development client 1;
[0062] The process of generating the compressed package sent by the module development client 3 includes the following steps:
[0063] Step S501: the module development client 3 receives the input module code in response to the module code input instruction.
[0064] Step S502: compile the input module code and its dependencies that need to be compiled;
[0065] Step S503: compress the compiled product and other dependencies that do not need to be compiled into a compressed package; it should be understood that, as in the above, the dependencies refer to the resources required for maintaining the normal operation of the received module code when the software development client 1 executes the received module code. This process is essentially the same as the content in the embodiment provided in the first aspect, and will not be repeated here.
[0066] The generation process of the compressed package name (not shown) includes: in response to the module configuration instruction, receiving the input module configuration code; the module configuration code includes: the compressed package name and the compressed package download path; in response to executing the download instruction, parsing the compressed package name in the module configuration code. The generation process is essentially the same as the content in the embodiment provided in the first aspect, and will not be repeated here.
[0067] Figure 6 The present invention is a schematic diagram of the overall process of a management method of a general package manager in one embodiment of the present application. In the module development stage, the module developer first writes the module code and submits it, and sets the automatic trigger function through the Gitlab server. When the module developer submits the code module in the module development client 3, it is automatically triggered; and the module code and its dependencies to be compiled are compiled into a computer-readable language; after the compilation is completed, the compiled product and other dependencies that do not need to be compiled are compressed; and the compressed product is uploaded to the cloud 2 for storage. The cloud 2 receives the compressed package uploaded from the module development client 3, and provides resource query and download services for the software development client 1. In the software development stage, the software developer first determines the compressed package to be downloaded through keyword retrieval (or other methods) in the cloud 2, and edits the module configuration script file according to the name of the compressed package. The package manager parses the aforementioned module configuration script file in the software development client 1 to obtain the compressed package name information and download path information configured in the file, and then can pass Figure 6 The module update script file in sends a request to download or update the compressed package to the cloud 2; and decompresses the downloaded compressed package, and stores the decompressed product in the local code repository for related code compilation during software development to generate a complete application software.
[0068] In some embodiments of the second aspect of the present application, it also includes: receiving a version update instruction and a compressed package name to be updated sent by the software development client 1, retrieving and matching a new version compressed package stored in the cloud 2 that is identical to the compressed package name except for the version number, and sending the new version compressed package to the software development client 1. The operation steps of the management method of a general package manager provided by the present application in the cloud and in the software development client are essentially the same, and will not be repeated here.
[0069] It should be noted that in the embodiments of the present application, words such as "exemplary" or "for example" represent examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.
[0070] In the embodiments of the present application, "at least one" refers to one or more, and "more" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can represent: a, b, c, ab, ac, bc or abc, where a, b, c can be single or multiple. To achieve the above purpose and other related purposes, the third aspect of the present application provides a computer device, including a memory, a processor and a computer program stored on the memory; the processor executes the computer program to implement the method.
[0071] Figure 7 is a schematic block diagram of a computer device provided in an embodiment of the present application. Figure 7 As shown in FIG. 1 , the computer device includes: at least one processor 701, a memory 702, at least one network interface 703 and a user interface 705. The various components in the device are coupled together via a bus system 704. It can be understood that the bus system 704 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 704 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, the bus system 704 is not described in detail. Figure 7 In the specification, various buses are labeled as bus systems.
[0072] The user interface 705 may include a display, a keyboard, a mouse, a trackball, a click gun, keys, buttons, a touch pad or a touch screen.
[0073] It is understood that the memory 702 can be a volatile memory or a non-volatile memory, and can also include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), which is used as an external cache. By way of exemplary but not limiting explanation, many forms of RAM are available, such as static random access memory (SRAM), synchronous static random access memory (SSRAM). The memory described in the embodiments of the present invention is intended to include but is not limited to these and any other suitable categories of memory.
[0074] The memory 702 in the embodiment of the present invention is used to store various types of data to support the operation of the electronic terminal 700. Examples of these data include: any executable program used to operate on the electronic terminal 700, such as an operating system 7021 and an application 7022; the operating system 7021 includes various system programs, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks. The application 7022 can include various applications, such as a media player (Media Player), a browser (Browser), etc., for implementing various application services. The method provided by the embodiment of the present invention can be included in the application 7022.
[0075] The method disclosed in the above embodiment of the present invention can be applied to the processor 701, or implemented by the processor 701. The processor 701 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit in the processor 701 or the instruction in the form of software. The above processor 701 may be a general processor, a digital signal processor (DSP, Digital Signal Processor), or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. The processor 701 can implement or execute the various methods, steps and logic block diagrams disclosed in the embodiment of the present invention. The general processor 701 may be a microprocessor or any conventional processor, etc. In combination with the steps of the accessory optimization method provided in the embodiment of the present invention, it can be directly embodied as a hardware decoding processor to execute, or it can be executed by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium, which is located in a memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.
[0076] In an exemplary embodiment, the electronic terminal 700 may be one or more application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), and complex programmable logic devices (CPLDs) for executing the aforementioned method. To achieve the above-mentioned purpose and other related purposes, a fourth aspect of the present application provides a computer-readable storage medium having a computer program stored thereon, and the computer program implements the method when executed by a processor.
[0077] According to the method provided in the embodiment of the present application, the present application also provides a computer-readable storage medium, which stores a program code, and when the program code is run on a computer, the computer executes Figures 1 to 5 A method according to any one of the embodiments shown.
[0078] To achieve the above-mentioned purpose and other related purposes, the fifth aspect of the present application provides a computer program product, which includes a computer program code. When the computer program code runs on a computer, the computer implements the method.
[0079] According to the method provided in the embodiment of the present application, the present application also provides a computer program product, which includes: a computer program code, when the computer program code is run on a computer, the computer executes Figures 1 to 5 A method according to any one of the embodiments shown.
[0080] The terms "component", "module", "system", etc. used in this specification are used to represent computer-related entities, hardware, firmware, a combination of hardware and software, software, or software in execution. For example, a component can be, but is not limited to, a process running on a processor, a processor, an object, an executable file, an execution thread, a program and / or a computer. By way of illustration, both applications running on a computing device and a computing device can be components. One or more components may reside in a process and / or an execution thread, and a component may be located on a computer and / or distributed between two or more computers. In addition, these components may be executed from various computer-readable media having various data structures stored thereon. Components may, for example, communicate through local and / or remote processes based on signals having one or more data packets (e.g., data from two components interacting with another component between a local system, a distributed system and / or a network, such as the Internet interacting with other systems through signals).
[0081] Those of ordinary skill in the art will appreciate that the various illustrative logical blocks and steps described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or in a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel may use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0082] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0083] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0084] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0085] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0086] In the above embodiments, the functions of each functional unit can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions (programs). When loading and executing computer program instructions (programs) on a computer, the process or function according to the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. Computer instructions can be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, computer instructions can be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (digital subscriber line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that contains one or more available media integrations. Available media may be magnetic media (e.g., floppy disks, hard disks, tapes), optical media (e.g., high-density digital video discs (DVDs), or semiconductor media (e.g., solid state disks (SSDs), etc.).
[0087] If the function is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, and other media that can store program codes.
[0088] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0089] In summary, the present application provides a management method of a package manager for managing software packages in a compressed package form, and its device, medium and program product, which effectively overcomes various shortcomings in the prior art and has high industrial utilization value.
[0090] The above embodiments are merely illustrative of the principles and effects of the present application and are not intended to limit the present application. Anyone familiar with the technology may modify or change the above embodiments without violating the spirit and scope of the present application. Therefore, all equivalent modifications or changes made by a person of ordinary skill in the art without departing from the spirit and technical ideas disclosed in the present application shall still be covered by the claims of the present application.
Claims
1. A general package manager management method, characterized in that: Applied to a software development client, the method includes: In response to the module configuration instruction, receiving the input module configuration code; the module configuration code includes: a compressed package name and a compressed package download path; In response to executing the download instruction, parsing the compressed package name and the compressed package download path in the module configuration code, and sending the parsed compressed package name to the cloud; Receiving a compressed package downloaded from the cloud with the same name as the parsed compressed package name, and storing it in the parsed compressed package download path; The generation process of the compressed package sent by the cloud includes: the cloud responds to the module code submission instruction and receives the compressed package sent by the module development client; the generation process of the compressed package sent by the module development client includes: the module development client responds to the module code input instruction, receives the input module code, and compiles the input module code and its dependencies that need to be compiled, and compresses the compiled product and other dependencies that do not need to be compiled into a compressed package and sends it to the cloud; the dependencies refer to the resources required to maintain the normal operation of the received module code when the software development client executes the received module code.
2. A general package manager management method according to claim 1, characterized in that: The components of the compressed package name include: module name and version number.
3. The method for managing a general package manager according to claim 1, characterized in that: The module configuration instruction is automatically triggered by the Gitlab server in response to a module code submission command.
4. The method for managing a general package manager according to claim 1, characterized in that: Also includes: Decompressing the compressed package stored in the parsed compressed package download path; Store the decompressed product in the local code repository of the software development client.
5. The method for managing a general package manager according to claim 1, characterized in that: Also includes: In response to the module version update instruction, receiving the input compressed package name and download path to be updated, and sending the version update instruction and the compressed package name to be updated to the cloud; Receive the new version compressed package sent by the cloud and store it in the entered download path.
6. A general package manager management method, characterized in that: Applied to the cloud, the method includes: In response to the module code submission instruction, a compressed package sent by the module development client is received; the generation process of the compressed package sent by the module development client includes: the module development client receives the input module code in response to the module code input instruction, compiles the input module code and its dependencies that need to be compiled, and compresses the compiled product and other dependencies that do not need to be compiled into a compressed package; the dependencies refer to the resources required for maintaining the normal operation of the received module code when the software development client executes the received module code; In response to executing the download instruction, receiving a compressed package name from the software development client, retrieving and matching a stored compressed package with the same compressed package name, and sending the compressed package to the software development client; The process of generating the compressed package name includes: receiving the input module configuration code in response to the module configuration instruction; the module configuration code includes: the compressed package name and the compressed package download path; in response to executing the download instruction, parsing the compressed package name in the module configuration code.
7. A general package manager management method according to claim 6, characterized in that: Also includes: Receive the version update instruction and the name of the compressed package to be updated sent by the software development client, retrieve and match the new version compressed package stored in the cloud that is identical to the compressed package name except the version number, and send the new version compressed package to the software development client.
8. A computer device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the method described in any one of claims 1 to 5, or implements the method described in any one of claims 6 to 7.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, it implements the method described in any one of claims 1 to 5, or implements the method described in any one of claims 6 to 7.
10. A computer program product, characterized in that The computer program product includes a computer program code, and when the computer program code is run on a computer, the computer is enabled to implement the method as described in any one of claims 1 to 5, or to implement the method as described in any one of claims 6 to 7.
Citation Information
Patent Citations
High-performance computing platform application packaging method and system and storage medium
CN114721706A
Application program compiling method and system, compiler and storage medium
CN117075907A
Packet manager adaptation method and device, equipment, storage medium and program product
CN117992133A
Software package processing method, apparatus, system, and device, and medium
WO2023045849A1
