A command help information checking method, device and equipment and readable storage medium

By automating the comparison of help information text with source files, the omissions and inefficiencies of manual verification are solved, achieving more efficient and accurate text verification.

CN115455932BActive Publication Date: 2026-05-29INSPUR SUZHOU INTELLIGENT TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INSPUR SUZHOU INTELLIGENT TECH CO LTD
Filing Date
2022-08-18
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

In existing technologies, the verification of command help information text relies on manual comparison, which is prone to missing characters and syntax errors, and is inefficient.

Method used

An automated method is used to compare the help information text of the command to be verified with the source file, use the Linux built-in comparison tool to detect differences, record the differences, and update the content of the source file.

Benefits of technology

It improves the accuracy and efficiency of command help information text verification, avoiding omissions and inefficiencies in manual verification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115455932B_ABST
    Figure CN115455932B_ABST
Patent Text Reader

Abstract

The application discloses a command help information checking method and device, equipment and a readable storage medium, and relates to the technical field of command verification. The method comprises the following steps: identifying a command to be checked, obtaining help information text corresponding to the command to be checked; obtaining a command help information source file corresponding to the command to be checked; comparing the help information text to be checked with the command help information source file, and determining whether there are difference points between the help information text to be checked and the command help information source file; and if there are one or more difference points between the help information text to be checked and the command help information source file, recording the one or more difference points in a checking result file. By implementing the command help information checking method disclosed in the application, the situation that characters are missed and syntax errors occur during manual checking work can be effectively avoided, the checking accuracy of the help information text of the command to be checked is improved, and the command help information text checking efficiency is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of command verification technology, and in particular to a method, apparatus, device, and readable storage medium for verifying command help information. Background Technology

[0002] The command-line interface is a crucial interactive page for operating systems. During system and feature development, storage operating systems encapsulate their own commands. Industry regulations require that help information be created for newly encapsulated commands. This help information details the command's usage, the rules for using its parameters, and the output results. Testing these newly encapsulated commands is a vital part of the development process for storage operating systems, and verifying the accuracy of the help information is an important aspect of testing it.

[0003] In the current development process, the accuracy of command help information text is typically checked manually by engineers during development, based on the source help information file. The consistency between the source help information file and the help information text output after executing the command is compared. Manual verification is prone to overlooking characters and syntax errors; furthermore, it is inefficient and can even impact development progress. Therefore, there is an urgent need for a command help information verification method, device, system, and readable storage medium to automatically compare the consistency between the help information text output after command execution and the command help information source file, thereby improving the accuracy and efficiency of text verification. Summary of the Invention

[0004] To address the issues of missing characters and syntax errors, as well as low verification efficiency, that may occur when manually verifying command help information text in existing technologies, this invention provides a command help information verification method, apparatus, device, and readable storage medium. This automatically verifies the command help information text based on the content recorded in the command help information source file, thus overcoming the problems of defective verification results and low operational efficiency.

[0005] To solve one or more of the above-mentioned technical problems, the present invention adopts the following technical solution:

[0006] Firstly, a method for verifying command help information is provided, the method including:

[0007] Identify the command to be verified and obtain the corresponding help information text for verification. The help information text for verification shall at least record the usage method of the command to be verified, the rules for using the parameters of the command to be verified, and the corresponding output results after executing the command to be verified.

[0008] Obtain the command help information source file corresponding to the command to be verified. The command help information source file shall at least record the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output result after executing the command to be verified.

[0009] Compare the help information text to be verified with the source file of the command help information, and determine whether there are any differences between the help information text to be verified and the source file of the command help information;

[0010] If there are one or more differences between the help information text to be verified and the source file of the command help information, then one or more differences will be recorded in the verification result file.

[0011] Furthermore, the help information text corresponding to the command to be verified includes:

[0012] Log in to the operating system command line;

[0013] Execute the command to be verified in the operating system's command-line interface;

[0014] Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

[0015] Furthermore, the source files for obtaining the command help information corresponding to the command to be verified include:

[0016] Retrieve the storage location of the command to be verified in the database from the background command entries;

[0017] Fetch the source file of command help information from the storage location in the database to the cache.

[0018] Furthermore, the text of the verification help information is compared with the source file of the command help information, including:

[0019] Use the built-in comparison tool in Linux to compare the content of the help information text to be verified with the content of the command help information source file.

[0020] Furthermore, after recording one or more discrepancies in the verification result file, the process also includes:

[0021] Based on one or more discrepancies recorded in the verification result file, update the specific content in the help information text to be verified corresponding to one or more discrepancies to the specific content in the command help information source file corresponding to the one or more discrepancies.

[0022] Furthermore, the command help information verification method also includes: deploying the command help information verification environment.

[0023] Furthermore, the deployment command help information verification environment includes:

[0024] Save the source file of the command help information corresponding to the command to be verified to the database;

[0025] Deploy a verification program for the command help information verification method.

[0026] Secondly, a command help information verification device is provided, the device comprising: a text to be verified acquisition module, a source file acquisition module, a file comparison module, and a result output module;

[0027] The module for obtaining the text to be verified is used to identify the command to be verified and obtain the corresponding help information text to be verified. The help information text to be verified shall at least record the usage method of the command to be verified, the parameter usage rules of the command to be verified, and the corresponding output results after executing the command to be verified.

[0028] The source file acquisition module is used to acquire the command help information source file corresponding to the command to be verified. The command help information source file shall at least record the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output result after executing the command to be verified.

[0029] The file comparison module is used to compare the help information text to be verified with the command help information source file, and to determine whether there are any differences between the help information text to be verified and the command help information source file.

[0030] The result output module is used to record one or more differences between the help information text to be verified and the source file of the command help information if there are one or more differences.

[0031] Thirdly, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, it implements the steps of the method described in the first aspect.

[0032] Fourthly, a computer-readable storage medium is provided, on which a computer program is stored, which, when executed by a processor, implements the steps of the method described in the first aspect. The beneficial effects of the technical solution provided by the embodiments of the present invention are:

[0033] 1. By implementing the command help information verification method disclosed in this invention, the occurrence of missing characters and syntax errors during manual verification can be effectively avoided, thereby improving the verification accuracy of the command help information text to be verified;

[0034] 2. Improve the efficiency of command help information text validation through automated validation methods. Attached Figure Description

[0035] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0036] Figure 1 This is a schematic diagram of a command help information verification method provided in an embodiment of the present invention;

[0037] Figure 2 This is a schematic diagram of a command help information verification device provided in an embodiment of the present invention;

[0038] Figure 3 This is a schematic diagram of a computer device for verifying command help information provided in an embodiment of the present invention. Detailed Implementation

[0039] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this invention.

[0040] Unless otherwise defined, the technical or scientific terms used in this disclosure shall have the ordinary meaning understood by one of ordinary skill in the art to which this disclosure pertains. The terms “first,” “second,” and similar terms used in this disclosure do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Similarly, the terms “an,” “a,” or “the,” and similar terms do not indicate a quantity limitation, but rather indicate the presence of at least one. The numbers in the accompanying drawings are only used to distinguish individual functional parts or modules and do not indicate logical relationships between parts or modules. The terms “comprising,” “including,” or “including,” and similar terms mean that the element or object preceding the term encompasses the element or object listed following the term and its equivalents, without excluding other elements or objects. The terms “connected,” “linked,” and similar terms are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. “Above,” “below,” “left,” “right,” etc., are used only to indicate relative positional relationships; when the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0041] The various embodiments according to this disclosure will now be described in detail with reference to the accompanying drawings. It should be noted that in the drawings, the same reference numerals are assigned to components having substantially the same or similar structure and function, and repeated descriptions of them will be omitted.

[0042] To address the shortcomings of existing technologies, embodiments of the present invention provide a method, apparatus, device, and readable storage medium for verifying command help information, thereby resolving the issues of poor verification accuracy and low verification efficiency when manually verifying the consistency between command help information text and command help information source files.

[0043] To address the issues of missing characters and syntax errors that may occur during manual verification of command help information text in existing technologies, as well as the problem of low verification efficiency, this invention provides a command help information verification method, apparatus, device, and readable storage medium. This automatically verifies command help information text based on the command content, replacing manual verification, thereby overcoming the problems of defective verification results and low operational efficiency.

[0044] In one embodiment, such as Figure 1 As shown, a method for verifying command help information includes:

[0045] Step S10: Identify the command to be verified and obtain the corresponding help information text to be verified. The help information text to be verified shall at least record the usage method of the command to be verified, the parameter usage rules of the command to be verified, and the corresponding output results after executing the command to be verified.

[0046] Step S20: Obtain the command help information source file corresponding to the command to be verified. The command help information source file shall at least record the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output result after executing the command to be verified.

[0047] Step S30: Compare the help information text to be verified with the command help information source file, and determine whether there are any differences between the help information text to be verified and the command help information source file.

[0048] Step S40: If there are one or more differences between the help information text to be verified and the command help information source file, record one or more differences in the verification result file.

[0049] Specifically, step S10: Obtaining the help information text corresponding to the command to be verified includes:

[0050] Step S11: Log in to the operating system command line;

[0051] Step S12: Execute the command to be verified in the operating system command line interface;

[0052] Step S13: Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

[0053] The help information text to be verified also contains the usage method and parameter usage rules for the command to be verified.

[0054] Specifically, step S20: Obtaining the source file of command help information corresponding to the command to be verified includes:

[0055] Step S21: Retrieve the storage location of the command to be verified in the database from the background command entries.

[0056] Step S22: Retrieve the source file of command help information from the storage location in the database to the cache.

[0057] Specifically, step S30: Comparing the text of the help information to be verified with the source file of the command help information includes:

[0058] Step S31: Use the LINUX built-in comparison tool to compare the content recorded in the help information text to be verified with the content recorded in the command help information source file.

[0059] The Linux system has built-in comparison tools including diff, vimdiff, DiffMerge, Meld, Diffuse, XXdiff, kDiff3, TkDiff, and Kompare, which are sufficient to meet the application scenario of this application. Therefore, one of these text difference comparison tools is directly called to compare the differences between the actual output and the corresponding output.

[0060] In one implementation, after recording one or more differences in the verification result file, the method further includes:

[0061] Step S41: Based on one or more discrepancies recorded in the verification result file, update the specific content in the help information text to be verified corresponding to one or more discrepancies to the specific content in the command help information source file corresponding to the one or more discrepancies.

[0062] Specifically, the command usage methods, command parameter usage rules, or command output results in the help information text to be verified that correspond to one or more differences are updated to match the command usage methods, command parameter usage rules, or command output results in the command help information source file that correspond to one or more differences. Content in the help text to be verified that does not contain differences is retained.

[0063] In one implementation, step S40': if there are no differences between the help information text to be verified and the command help information source file, then the verification result file records that the verification passed.

[0064] In one embodiment, a command help information verification method further includes:

[0065] Step S00: Deployment command help information verification environment.

[0066] Specifically, it includes:

[0067] Step S01: Save the source file of the command help information corresponding to the command to be verified to the database;

[0068] Step S02: Deploy a verification program for executing the command help information verification method.

[0069] In another embodiment, such as Figure 2 As shown, a command help information verification device includes: a text acquisition module, a source file acquisition module, a file comparison module, and a result output module;

[0070] The module for obtaining the text to be verified is used to identify the command to be verified and obtain the corresponding help information text to be verified.

[0071] The help information text to be verified must at least record the usage method of the command to be verified, the rules for using the parameters of the command to be verified, and the corresponding output results after executing the command to be verified.

[0072] The source file acquisition module is used to acquire the source file of the command help information corresponding to the command to be verified.

[0073] The command help information source file should at least record the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output results after executing the command to be verified.

[0074] The file comparison module is used to compare the help information text to be verified with the command help information source file, and to determine whether there are any differences between the help information text to be verified and the command help information source file.

[0075] The result output module is used to record one or more differences between the help information text to be verified and the source file of the command help information if there are one or more differences.

[0076] In another embodiment, such as Figure 3As shown, a computer device includes a non-volatile storage medium as memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the command help information verification method described in the first aspect above, specifically including:

[0077] Step S10: Identify the command to be verified and obtain the corresponding help information text for verification.

[0078] Specifically, this includes: Step S11: Log in to the operating system command line;

[0079] Step S12: Execute the command to be verified in the operating system command line interface;

[0080] Step S13: Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

[0081] Step S20: Obtain the source file of the command help information corresponding to the command to be verified.

[0082] Specifically, this includes: Step S21: Retrieve the storage location of the command to be verified in the database from the background command entries.

[0083] Step S22: Retrieve the source file of command help information from the storage location in the database to the cache.

[0084] Step S30: Compare the help information text to be verified with the command help information source file, and determine whether there are any differences between the help information text to be verified and the command help information source file.

[0085] Specifically, this includes: Step S31: Using the LINUX built-in comparison tool, compare the content recorded in the help information text to be verified with the content recorded in the command help information source file.

[0086] Step S40: If there are one or more differences between the help information text to be verified and the command help information source file, record one or more differences in the verification result file.

[0087] In one embodiment, the method further includes step S41: based on one or more discrepancies recorded in the verification result file, update the specific content in the help information text to be verified corresponding to one or more discrepancies to the specific content in the command help information source file corresponding to the corresponding position of one or more discrepancies.

[0088] In one embodiment, a command help information verification method further includes:

[0089] Step S00: Deployment command help information verification environment.

[0090] Specifically, it includes:

[0091] Step S01: Save the source file of the command help information corresponding to the command to be verified to the database;

[0092] Step S02: Deploy a verification program for executing the command help information verification method.

[0093] In another embodiment, a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the command help information verification method described in the first aspect above, specifically including:

[0094] Step S10: Identify the command to be verified and obtain the corresponding help information text for verification.

[0095] Specifically, this includes: Step S11: Log in to the operating system command line;

[0096] Step S12: Execute the command to be verified in the operating system command line interface;

[0097] Step S13: Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

[0098] Step S20: Obtain the source file of the command help information corresponding to the command to be verified.

[0099] Specifically, this includes: Step S21: Retrieve the storage location of the command to be verified in the database from the background command entries.

[0100] Step S22: Retrieve the source file of command help information from the storage location in the database to the cache.

[0101] Step S30: Compare the help information text to be verified with the command help information source file, and determine whether there are any differences between the help information text to be verified and the command help information source file.

[0102] Specifically, this includes: Step S31: Using the LINUX built-in comparison tool, compare the content recorded in the help information text to be verified with the content recorded in the command help information source file.

[0103] Step S40: If there are one or more differences between the help information text to be verified and the command help information source file, record one or more differences in the verification result file.

[0104] In one embodiment, the method further includes step S41: based on one or more discrepancies recorded in the verification result file, update the specific content in the help information text to be verified corresponding to one or more discrepancies to the specific content in the command help information source file corresponding to the corresponding position of one or more discrepancies.

[0105] In one embodiment, a command help information verification method further includes:

[0106] Step S00: Deployment command help information verification environment.

[0107] Specifically, it includes:

[0108] Step S01: Save the source file of the command help information corresponding to the command to be verified to the database;

[0109] Step S02: Deploy a verification program for executing the command help information verification method.

[0110] All of the above-mentioned optional technical solutions can be combined in any way to form optional embodiments of the present invention, and will not be described in detail here.

[0111] Example 1

[0112] The following is combined with Figure 1 This paper specifically describes a method for verifying command help information, including:

[0113] Step S10: Identify the command to be verified and obtain the corresponding help information text to be verified. The help information text to be verified shall at least record the usage method of the command to be verified, the parameter usage rules of the command to be verified, and the corresponding output results after executing the command to be verified.

[0114] Step S20: Obtain the command help information source file corresponding to the command to be verified. The command help information source file shall at least record the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output result after executing the command to be verified.

[0115] Step S30: Compare the help information text to be verified with the command help information source file, and determine whether there are any differences between the help information text to be verified and the command help information source file.

[0116] Step S40: If there are one or more differences between the help information text to be verified and the command help information source file, record one or more differences in the verification result file.

[0117] Example 2

[0118] A method for verifying command help information includes:

[0119] Step S00: Deployment command help information verification environment.

[0120] Step S01: Save the source file of the command help information corresponding to the command to be verified to the database.

[0121] Step S02: Deploy a verification program for executing the command help information verification method.

[0122] Step S10: Identify the command to be verified and obtain the corresponding help information text for verification.

[0123] Specifically, this includes: Step S11: Log in to the operating system command line;

[0124] Step S12: Execute the command to be verified in the operating system command line interface;

[0125] Step S13: Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

[0126] Step S20: Obtain the source file of the command help information corresponding to the command to be verified.

[0127] Specifically, this includes: Step S21: Retrieve the storage location of the command to be verified in the database from the background command entries.

[0128] Step S22: Retrieve the source file of command help information from the storage location in the database to the cache.

[0129] Step S30: Compare the help information text to be verified with the command help information source file, and determine whether there are any differences between the help information text to be verified and the command help information source file.

[0130] Specifically, this includes: Step S31: Using the LINUX built-in comparison tool, compare the content recorded in the help information text to be verified with the content recorded in the command help information source file.

[0131] Step S40: If there are one or more differences between the help information text to be verified and the command help information source file, record one or more differences in the verification result file.

[0132] The next step is S41: based on one or more discrepancies recorded in the verification result file, update the specific content in the help information text to be verified corresponding to one or more discrepancies to the specific content in the command help information source file corresponding to the one or more discrepancies at the corresponding positions.

[0133] Example 3

[0134] The following is combined with Figure 2This paper details a command help information verification device.

[0135] A command help information verification device includes: a text acquisition module, a source file acquisition module, a file comparison module, and a result output module;

[0136] The module for obtaining the text to be verified is used to identify the command to be verified and obtain the corresponding help information text to be verified.

[0137] The help information text to be verified must at least record the usage method of the command to be verified, the rules for using the parameters of the command to be verified, and the corresponding output results after executing the command to be verified.

[0138] The source file acquisition module is used to acquire the source file of the command help information corresponding to the command to be verified.

[0139] The command help information source file should at least record the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output results after executing the command to be verified.

[0140] The file comparison module is used to compare the help information text to be verified with the command help information source file, and to determine whether there are any differences between the help information text to be verified and the command help information source file.

[0141] The result output module is used to record one or more differences between the help information text to be verified and the source file of the command help information if there are one or more differences.

[0142] Example 4

[0143] The following is combined with Figure 3 Specifically, a computer device is described, including a non-volatile storage medium as memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the command help information verification method described in the first aspect above, specifically including:

[0144] Step S10: Identify the command to be verified and obtain the corresponding help information text for verification.

[0145] Specifically, this includes: Step S11: Log in to the operating system command line;

[0146] Step S12: Execute the command to be verified in the operating system command line interface;

[0147] Step S13: Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

[0148] Step S20: Obtain the source file of the command help information corresponding to the command to be verified.

[0149] Specifically, this includes: Step S21: Retrieve the storage location of the command to be verified in the database from the background command entries.

[0150] Step S22: Retrieve the source file of command help information from the storage location in the database to the cache.

[0151] Step S30: Compare the help information text to be verified with the command help information source file, and determine whether there are any differences between the help information text to be verified and the command help information source file.

[0152] Specifically, this includes: Step S31: Using the LINUX built-in comparison tool, compare the content recorded in the help information text to be verified with the content recorded in the command help information source file.

[0153] Step S40: If there are one or more differences between the help information text to be verified and the command help information source file, record one or more differences in the verification result file.

[0154] In one embodiment, the method further includes step S41: based on one or more discrepancies recorded in the verification result file, update the specific content in the help information text to be verified corresponding to one or more discrepancies to the specific content in the command help information source file corresponding to the corresponding position of one or more discrepancies.

[0155] In one embodiment, a command help information verification method further includes:

[0156] Step S00: Deployment command help information verification environment.

[0157] Specifically, it includes:

[0158] Step S01: Save the source file of the command help information corresponding to the command to be verified to the database;

[0159] Step S02: Deploy a verification program for executing the command help information verification method.

[0160] Example 5

[0161] A computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the command help information verification method described in the first aspect above, specifically including:

[0162] Step S10: Identify the command to be verified and obtain the corresponding help information text for verification.

[0163] Specifically, this includes: Step S11: Log in to the operating system command line;

[0164] Step S12: Execute the command to be verified in the operating system command line interface;

[0165] Step S13: Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

[0166] Step S20: Obtain the source file of the command help information corresponding to the command to be verified.

[0167] Specifically, this includes: Step S21: Retrieve the storage location of the command to be verified in the database from the background command entries.

[0168] Step S22: Retrieve the source file of command help information from the storage location in the database to the cache.

[0169] Step S30: Compare the help information text to be verified with the command help information source file, and determine whether there are any differences between the help information text to be verified and the command help information source file.

[0170] Specifically, this includes: Step S31: Using the LINUX built-in comparison tool, compare the content recorded in the help information text to be verified with the content recorded in the command help information source file.

[0171] Step S40: If there are one or more differences between the help information text to be verified and the command help information source file, record one or more differences in the verification result file.

[0172] In one embodiment, the method further includes step S41: based on one or more discrepancies recorded in the verification result file, update the specific content in the help information text to be verified corresponding to one or more discrepancies to the specific content in the command help information source file corresponding to the corresponding position of one or more discrepancies.

[0173] In one embodiment, a command help information verification method further includes:

[0174] Step S00: Deployment command help information verification environment.

[0175] Specifically, it includes:

[0176] Step S01: Save the source file of the command help information corresponding to the command to be verified to the database;

[0177] Step S02: Deploy a verification program for executing the command help information verification method.

[0178] Specifically, according to embodiments of this application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, embodiments of this application include a computer program product comprising a computer program loaded on a computer-readable medium, the computer program containing program code for performing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network via a communication device, or installed from memory, or installed from ROM. When the computer program is executed by an external processor, it performs the functions defined in the methods of embodiments of this application.

[0179] It should be noted that the computer-readable medium in the embodiments of this application can be a computer-readable signal medium or a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In the embodiments of this application, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In the embodiments of this application, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium can be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wires, optical fibers, RF (Radio Frequency), etc., or any suitable combination thereof.

[0180] The aforementioned computer-readable medium may be included in the aforementioned server; or it may exist independently and not assembled into the server. The aforementioned computer-readable medium carries one or more programs that, when executed by the server, cause the server to: in response to detecting that the peripheral mode of the terminal is not activated, acquire the frame rate of the application on the terminal; when the frame rate meets the screen-off condition, determine whether the user is acquiring the terminal's screen information; and in response to the determination that the user is not acquiring the terminal's screen information, control the screen to enter an immediate dimming mode.

[0181] Computer program code for performing the operations of the embodiments of this application can be written in one or more programming languages ​​or a combination thereof. Programming languages ​​include object-oriented programming languages—such as Java, Smalltalk, and C++—and conventional procedural programming languages—such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0182] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, for system or system embodiments, since they are basically similar to method embodiments, the description is relatively simple, and relevant parts can be referred to the descriptions in the method embodiments. The systems and system embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without creative effort.

[0183] The technical solutions provided in this application have been described in detail above. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the above embodiments are only for the purpose of helping to understand the methods and core ideas of this application. Furthermore, those skilled in the art will recognize that, based on the ideas of this application, there will be changes in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as a limitation of this application.

[0184] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for verifying command help information, characterized in that, The method includes: Identify the command to be verified, and obtain the corresponding help information text to be verified, wherein the help information text to be verified at least records the usage method of the command to be verified, the parameter usage rules of the command to be verified, and the corresponding output results after executing the command to be verified; Obtain the command help information source file corresponding to the command to be verified, wherein the command help information source file at least records the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output result after executing the command to be verified; Using the built-in comparison tool in Linux, the content recorded in the help information text to be verified is compared with the content recorded in the command help information source file. If there is a difference between the actual output result and the corresponding output result, the difference between the actual output result and the corresponding output result is taken as the difference point. If there are one or more differences between the help information text to be verified and the source file of the command help information, then the one or more differences will be recorded in the verification result file.

2. The command help information verification method according to claim 1, characterized in that, The step of obtaining the help information text corresponding to the command to be verified includes: Log in to the operating system command line; Execute the command to be verified in the operating system command-line interface; Save the corresponding output results after executing the command to be verified to the help information text file to be verified.

3. The command help information verification method according to claim 1, characterized in that, The process of obtaining the source file of command help information corresponding to the command to be verified includes: Retrieve the storage location of the command to be verified in the database from the background command entries; Retrieve the source file of the command help information from the storage location in the database to the cache.

4. The command help information verification method according to claim 1, characterized in that, The step of recording the one or more differences in the verification result file further includes: Based on the one or more differences recorded in the verification result file, update the specific content in the help information text to be verified corresponding to the one or more differences to the specific content in the command help information source file corresponding to the one or more differences.

5. A method for verifying command help information according to any one of claims 1 to 4, characterized in that, The method also includes, prior to: deploying command help information to verify the environment.

6. A method for verifying command help information according to claim 5, characterized in that, The deployment command help information verification environment includes: Save the source file of the command help information corresponding to the command to be verified to the database; Deploy a verification program for executing the command help information verification method.

7. A command help information verification device, characterized in that, The device includes: a text acquisition module, a source file acquisition module, a file comparison module, and a result output module; The text to be verified acquisition module is used to identify the command to be verified and acquire the help information text to be verified corresponding to the command to be verified. The help information text to be verified at least records the usage method of the command to be verified, the parameter usage rules of the command to be verified, and the corresponding output results after executing the command to be verified. The source file acquisition module is used to acquire the command help information source file corresponding to the command to be verified. The command help information source file at least records the standard usage method of the command to be verified, the standard parameter usage rules in the command to be verified, and the standard output result after executing the command to be verified. The file comparison module is used to compare the content recorded in the help information text to be verified with the content recorded in the command help information source file using the LINUX embedded comparison tool. If there is a difference between the actual output result and the corresponding output result, the difference between the actual output result and the corresponding output result is taken as the difference point. The result output module is used to record one or more differences between the help information text to be verified and the command help information source file in the verification result file.

8. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

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 steps of the method according to any one of claims 1 to 6.