CN108563440A - The automatic adding method of List Controller code, device and readable storage medium storing program for executing - Google Patents

The automatic adding method of List Controller code, device and readable storage medium storing program for executing Download PDF

Info

Publication number
CN108563440A
CN108563440A CN201810386430.XA CN201810386430A CN108563440A CN 108563440 A CN108563440 A CN 108563440A CN 201810386430 A CN201810386430 A CN 201810386430A CN 108563440 A CN108563440 A CN 108563440A
Authority
CN
China
Prior art keywords
template file
basic class
directory
class template
code
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201810386430.XA
Other languages
Chinese (zh)
Other versions
CN108563440B (en
Inventor
汪刚
张文明
陈少杰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Wuhan Douyu Network Technology Co Ltd
Original Assignee
Wuhan Douyu Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Wuhan Douyu Network Technology Co Ltd filed Critical Wuhan Douyu Network Technology Co Ltd
Priority to CN201810386430.XA priority Critical patent/CN108563440B/en
Publication of CN108563440A publication Critical patent/CN108563440A/en
Application granted granted Critical
Publication of CN108563440B publication Critical patent/CN108563440B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/36Software reuse

Abstract

A kind of automatic adding method of List Controller code of offer of the embodiment of the present invention, device and readable storage medium storing program for executing.This method includes:Server receives the basic class template file of user terminal uploads;A warehouse GIT is created, after in the storage to the warehouses GIT of basic class template file, obtains basic class template file corresponding warehouse address in the warehouses GIT, and warehouse address is fed back into user terminal;When needing to download basic class template file, user terminal responds shell script operating instructions, creates a template directory for storing basic class template file;It will be in the basic class template file download to template directory in server by warehouse address;Instruction processing is carried out to downloading the basic class template file completed, the code that instruction is handled is added under the specified directory of developing instrument, to realize that code adds.Thereby, it is possible to realize that List Controller often uses the multiplexing of code, the efficiency of writing of similar codes is improved as far as possible, reduces developer's workload.

Description

The automatic adding method of List Controller code, device and readable storage medium storing program for executing
Technical field
The present invention relates to technical field of software development, in particular to a kind of List Controller code side of addition automatically Method, device and readable storage medium storing program for executing.
Background technology
With the fast development of mobile phone mobile terminal, often there are some codes to be all commonly used in software development, than It such as needs to create a list, then list needs to create a List Controller, there is the data of list inside List Controller Source method, the Proxy Method of list, the data source method and Proxy Method of list are relatively more fixed, the life cycle of List Controller Method is also more fixed, and it is also fixed succession mode generally in an app to create list to need a model, model , it is also fixed that List Controller, which needs list cell, list cell, need to build each time list block when It waits, is required for creating List Controller, the model of list, the view of list.And list above controller, the model of list, The view format of list is similar with literary style.In short, needing to write the code much repeated when building a list block, such as What realizes the multiplexing of code, improves the efficiency of writing of similar codes as far as possible, reduces developer's workload, be art technology Personnel's technical problem urgently to be resolved hurrily.
Invention content
In order to overcome above-mentioned deficiency in the prior art, the purpose of the present invention is to provide a kind of List Controller codes certainly Dynamic adding method, device and readable storage medium storing program for executing can realize that List Controller often uses the multiplexing of code, improve as far as possible similar Code writes efficiency, reduces developer's workload.
To achieve the goals above, technical solution used in the embodiment of the present invention is as follows:
In a first aspect, the embodiment of the present invention provides a kind of automatic adding method of List Controller code, be applied to mutually it Between the server and user terminal that communicate to connect, the method includes:
The server receives the basic class template file of the user terminal uploads, is wrapped in the basic class template file Dynamic class template file and script type template file are included;
A warehouse GIT is created, after in the basic class template file storage to the warehouses GIT, obtains the basic class Template file corresponding warehouse address in the warehouses GIT, and the warehouse address is fed back into the user terminal;
When needing to download the basic class template file, the user terminal responds shell script operating instructions, creates One template directory for storing the basic class template file;
It will be in the basic class template file download to the template directory in the server by the warehouse address;
Instruction processing is carried out to downloading the basic class template file completed, the code that instruction is handled is added to exploitation Under the specified directory of tool, to realize that code adds.
Optionally, the user terminal responds shell script operating instructions, creates one for storing the basic class mould The step of template directory of plate file, including:
Whether in operating status detect shell scripts;
When detecting that the shell scripts are in operating status, false form parameter is defined;
By the false form parameter in one false form catalogue of directory creating where the shell scripts.
Optionally, the method further includes:
It responds shell scripts and creates instruction, create a shell script, and add fixation in the shell scripts and refer to It enables.
Optionally, it is described by the warehouse address by the basic class template file download in the server to the mould Step in plate catalogue, including:
From the basic class template file searched in the server under the warehouse address directory;
It will be in the basic class template file download to the template directory of establishment that found.
Optionally, the described pair of basic class template file for downloading completion carries out instruction processing, the generation that instruction is handled Code is added under the specified directory of developing instrument, to realize the step of code adds, including:
Return to the upper level catalogue of current shell scripts, obtain active user's working directory absolute path and it is described absolutely To the absolute address in path;
The address of the template directory is obtained, and the address based on the template directory is in the next stage of the template directory Basic class template file in the template directory is copied to described open by the specified directory that a developing instrument is created under catalogue In the specified directory of hair tool, to realize that code adds.
Optionally, instruction processing is being carried out to downloading the basic class template file completed, the code that instruction is handled It is added under the specified directory of developing instrument, after realizing the step of code adds, the method further includes:
The upper level catalogue for returning to the template directory deletes the All Files under the template directory, by code It removes.
Second aspect, the embodiment of the present invention also provide a kind of automatic adding method of List Controller code, are applied to and clothes The user terminal of business device communication connection, the method includes:
Basic class template file is uploaded into the server, so that the server receives the basic class template file And a warehouse GIT is created, the basic class template text is obtained after by the basic class template file storage to the warehouses GIT Part corresponding warehouse address in the warehouses GIT includes dynamic class template file and foot in the basic class template file This class template file;
The warehouse address that the server is sent is received, when needing to download the basic class template file, responds shell Script operating instruction creates a template directory for storing the basic class template file;
It will be in the basic class template file download to the template directory in the server by the warehouse address;
Instruction processing is carried out to downloading the basic class template file completed, the code that instruction is handled is added to exploitation Under the specified directory of tool, to realize that code adds.
The third aspect, the embodiment of the present invention also provide a kind of code automatic adding device, are applied to connect with server communication The user terminal connect, described device include:
Uploading module, for basic class template file to be uploaded to the server, so that described in server reception Basic class template file simultaneously creates a warehouse GIT, and institute is obtained after by the basic class template file storage to the warehouses GIT Basic class template file corresponding warehouse address in the warehouses GIT is stated, includes dynamic in the basic class template file Class template file and script type template file;
Receiving module, the warehouse address sent for receiving the server, when needing to download the basic class template text When part, shell script operating instructions are responded, create a template directory for storing the basic class template file;
Download module is used for the basic class template file download in the server through the warehouse address described in In template directory;
Code add module is handled instruction for carrying out instruction processing to downloading the basic class template file completed To code be added under the specified directory of developing instrument, with realize code add.
Fourth aspect, the embodiment of the present invention also provide a kind of readable storage medium storing program for executing, are stored in the readable storage medium storing program for executing Computer program, the computer program, which is performed, realizes the above-mentioned automatic adding method of List Controller code.
In terms of existing technologies, the invention has the advantages that:
A kind of automatic adding method of List Controller code of offer of the embodiment of the present invention, device and readable storage medium storing program for executing, it is first First, server receives the basic class template file of user terminal uploads, and creates a warehouse GIT, by basic class template file After storing in the warehouses GIT, basic class template file corresponding warehouse address in the warehouses GIT is obtained, and warehouse address is anti- It feeds user terminal, when needing to download basic class template file, user terminal responds shell script operating instructions, creates one A template directory for storing basic class template file, and will be under the basic class template file in server by warehouse address It is downloaded in template directory, then, carries out instruction processing to downloading the basic class template file completed, the generation that instruction is handled Code is added under the specified directory of developing instrument, to realize that code adds.As a result, by by the common basic class of List Controller The warehouses GIT that template file is uploaded onto the server obtain warehouse address, and developer is facilitated to download generation by this warehouse address Code updates newest block code, and facilitates scripting, and by running shell scripts, to can be realized as List Controller normal With the multiplexing of code, the efficiency of writing of similar codes is improved as far as possible, reduces developer's workload.
Description of the drawings
In order to illustrate the technical solution of the embodiments of the present invention more clearly, below will be to needed in the embodiment attached Figure is briefly described, it should be understood that the following drawings illustrates only certain embodiments of the present invention, therefore is not construed as pair The restriction of range.
Fig. 1 is the application scenarios schematic diagram of the automatic adding method of List Controller code provided in an embodiment of the present invention;
Fig. 2 is a kind of flow diagram of the automatic adding method of List Controller code provided in an embodiment of the present invention;
Fig. 3 is another flow diagram of the automatic adding method of List Controller code provided in an embodiment of the present invention;
Fig. 4 is that the user provided in an embodiment of the present invention for realizing the above-mentioned automatic adding method of List Controller code is whole The structural schematic block diagram at end.
Icon:100- user terminals;110- memories;120- processors;200- servers;300- codes add dress automatically It sets;310- uploading modules;320- receiving modules;330- download modules;340- code add modules.
Specific implementation mode
It should be noted that:Similar label and letter indicate similar terms in following attached drawing, therefore, once a certain Xiang Yi It is defined, then it further need not be defined and explained in subsequent attached drawing in a attached drawing.
Referring to Fig. 1, the application scenarios for the automatic adding method of List Controller code provided in an embodiment of the present invention show It is intended to, in the present embodiment, it is whole that the automatic adding method of List Controller code is applied to the user communicated to connect between each other End 100 and server 200.
The user terminal 100 can be for developer carry out software development electronic equipment, such as PC, Laptop etc..
The server 200 should be understood offer processing, data bank, communications service service point.For example, it services Device 200, which can refer to single physical processor with related communication and data storage and document library facility or it, can refer to connection The aggregate of net or the processor gathered, related network and storing unit, and to software and one or more document library systems The application software of the service provided with support server 200 is operated.Server 200 can in configuration or performance difference It is very big, but server 200 generally may include one or more central processing unit and storage unit.Server 200 may be used also To include one or more large-scale storage area equipment, one or more power supplys, one or more wired or wireless network components, one A or multiple input/output precision or one or more operating system, such as, Windows Server, Mac OS X, Unix, Linux、FreeBSD。
Referring to Fig. 2, a kind of flow for the automatic adding method of List Controller code provided in an embodiment of the present invention is shown It is intended to, the method user terminal 100 and server 200 shown in Fig. 1 execute.It should be noted that the present invention is implemented The automatic adding method of List Controller code that example provides is not limitation with Fig. 2 and particular order as described below.The method Detailed process it is as follows:
Step S110, server 200 receive the basic class template file that user terminal 100 uploads.
Include dynamic class template file and script type template file in the basic class template file in the present embodiment. Dynamic class template file includes some foundation codes, some classes of these foundation codes be it is fixed, for fixed class can be with The fixed class name of addition needs to the class name dynamically write if be not fixed if, and it refers to class name by two parts structure dynamically to write At a part is fixed, and a part is unfixed, and unfixed part is named according to setting.
In practical item development, other than above-mentioned dynamic class template file, it is also necessary to some script type template files, Or xib classes, plist files etc..Dynamic class template file and script type template file are being created, by dynamic class template text Part and script type template file upload in the server 200.
Step S120 creates a warehouse GIT, after in the basic class template file storage to the warehouses GIT, obtains institute Basic class template file corresponding warehouse address in the warehouses GIT is stated, and the warehouse address is fed back into the user Terminal 100.
In the present embodiment, the server 200 creates a warehouse GIT after receiving the basic class template file, By in the above-mentioned basic class template file storage to the warehouses GIT received, the basic class mould can get after storing successfully Plate file corresponding warehouse address gitAddress in the warehouses GIT is then anti-by the warehouse address gitAddress It feeds the user terminal 100.
Step S130, when needing to download the basic class template file, the user terminal 100 responds shell scripts Operating instruction creates a template directory for storing the basic class template file.
In the present embodiment, the basic class template file is quickly created and used in order to realize, is pre-configured with shell feet This, creates instruction by responding shell scripts, creates a shell script, and add fixation in the shell scripts and refer to It enables, specifically, can be by writing an entitled .sh of file suffixes, namely represent and write a shell script, in this foot Originally addition first command # is write!/ bin/bash, this is a fixed instruction for shell scripts.
After configuring shell scripts, whether the detection shell scripts of the user terminal 100 are in operating status, detecting When in operating status to the shell scripts, one can be arranged by defining false form parameter template, template variable A Chinese is template, then by the false form parameter in one interim mould of directory creating where the shell scripts Plate catalogue.It is alternatively possible to using the instruction mkdir to create a directory, pass through the instruction needs to create a directory Then template variables use mkdir orders that can create a template for storing the basic class template file Catalogue Content.
Step S140, by the warehouse address by the basic class template file download in the server 200 to described In template directory.
In the present embodiment, user terminal 100 can be searched basic under the warehouse address directory from the server 200 Class template file, will be in the basic class template file download to the template directory of establishment that found.It is alternatively possible to Using the instruction cd entered under ontent catalogues, under the catalogue Content of establishment, then entered using shell functions It, will be under the basic class template file below gitAddress catalogues using git clone instructions after under the catalogue Content of establishment It is downloaded under the catalogue Content of establishment, to realize the basic class template file download by server-side is uploaded to locally.
Optionally, in order to ensure download reliability, can use if (!$) whether judge basic class template file download It finishes, step S150 is carried out if downloading to finish.
Step S150 carries out instruction processing, the code that instruction is handled to downloading the basic class template file completed It is added under the specified directory of developing instrument, to realize that code adds.
In the present embodiment, the upper level catalogue of current shell scripts is returned first, obtains the exhausted of active user's working directory To the absolute address in path and the absolute path, the address of the template directory is then obtained, and be based on the template directory Address the specified directory of a developing instrument is created under the next stage catalogue of the template directory, will be in the template directory Basic class template file copy in the specified directory of the developing instrument, with realize code add.
It is, for example, possible to use cd orders return to the upper level catalogue of current shell scripts, cd orders need parameter Then dirname $ 0 use pwd orders to obtain the absolute path of active user's working directory, reuse $ orders and obtain absolutely The absolute address in path.Then, the address path1 of the template is obtained, the address path of the template is in developing instrument Position is fixed, a more fixed catalogue of the template in developing instrument.Then, the specified mesh of a developing instrument is created Record, a template of the specified directory under the catalogue of path1 are the catalogue of suffix, and suffix is the file of template Absolute address is path2.Then, it is created a directory using mkdir orders, mkdir orders need a parameter, this parameter It is path1, the All Files below rm orders removal path2 catalogues is then used, using cp orders by the file below path1 It copies in path2, thus the basic class template file in the template directory can be copied to the developing instrument In specified directory, to realize that code adds.
As a result, by by basic class template file upload onto the server 200 the warehouses GIT obtain warehouse address, conveniently open Hair personnel download code to update newest block code by this warehouse address, and facilitate scripting, pass through operation Shell scripts can be realized as the multiplexing that List Controller often uses code, improves the efficiency of writing of similar codes as far as possible, reduces Developer's workload.
Optionally, after the step S150, the user terminal 100 returns to the template after adding code All Files under the template directory are deleted, code are removed by the upper level catalogue of catalogue.It is, for example, possible to use cd Order returns under upper level catalogue, deletes all the elements below Content catalogues using rm orders, rm needs to use f parameters Force Deletion is represented, while needing recurrence order, it is to carry out the All Files below a file that so-called recurrence, which is deleted, It deletes.The removing to dead code is completed as a result, saves memory space.
Further, referring to Fig. 3, the embodiment of the present invention also provides a kind of automatic adding method of List Controller code, Unlike above example, the automatic adding method of this List Controller code user terminal 100 shown in Fig. 1 is held Row, it is to be understood that real above the step of involved in the automatic adding method of List Controller code next to be described It applies in example and has been noted above, the exhaustive of specific each step can refer to above embodiment description, below only to family terminal Step is executed to be briefly described.
Basic class template file is uploaded to the server 200 by step S310.
In the present embodiment, the server 200 receives the basic class template file and creates a warehouse GIT, is inciting somebody to action It is corresponding in the warehouses GIT that the basic class template file is obtained after in the basic class template file storage to the warehouses GIT Warehouse address, include dynamic class template file and script type template file in the basic class template file.
Step S320 receives the warehouse address of the transmission of the server 200, when needing to download the basic class template file When, shell script operating instructions are responded, a template directory for storing the basic class template file is created.
Step S330, by the warehouse address by the basic class template file download in the server 200 to described In template directory.
Step S340 carries out instruction processing, the code that instruction is handled to downloading the basic class template file completed It is added under the specified directory of developing instrument, to realize that code adds.
In the present embodiment, user terminal 100 can obtain current use by the upper level catalogue of the current shell scripts of return The absolute address of the absolute path of family working directory and the absolute path, and the address of the template directory is obtained, and be based on The address of the template directory creates the specified directory of a developing instrument under the next stage catalogue of the template directory, by institute The basic class template file stated in template directory copies in the specified directory of the developing instrument, to realize that code adds.
Referring to Fig. 4, being the use provided in an embodiment of the present invention for realizing the automatic adding method of List Controller code The structural schematic block diagram of family terminal 100.In the present embodiment, the user terminal 100 includes code automatic adding device 300, deposits Reservoir 110 and processor 120.In embodiments of the present invention, code automatic adding device 300 include it is at least one can be with software Or the form of firmware (Firmware) is stored in the memory 110 or is solidificated in the operating system of the server 200 Software function module in (Operating System, OS).The processor 120 is deposited for executing in the memory 110 The executable software module of storage, for example, the software function module included by the code automatic adding device 300 and computer journey Sequence etc..In the present embodiment, the code automatic adding device 300 can also be integrated in the operating system, as the behaviour Make a part for system.Specifically, the code automatic adding device 300 may include:
Uploading module 310, for basic class template file to be uploaded to the server 200, so that the server 200 It receives the basic class template file and creates a warehouse GIT, will be during the basic class template file stores to the warehouses GIT After obtain the basic class template file corresponding warehouse address in the warehouses GIT, wrapped in the basic class template file Dynamic class template file and script type template file are included.
Receiving module 320, the warehouse address for receiving the transmission of the server 200, when needing to download the basic class When template file, shell script operating instructions are responded, create a template mesh for storing the basic class template file Record.
Download module 330, for passing through the warehouse address by the basic class template file download in the server 200 Into the template directory.
Code add module 340 is handled instruction for carrying out instruction processing to downloading the basic class template file completed Obtained code is added under the specified directory of developing instrument, to realize that code adds.
Further, present pre-ferred embodiments also provide a kind of readable storage medium storing program for executing, are deposited in the readable storage medium storing program for executing Computer program is contained, the computer program realizes the above-mentioned automatic adding method of List Controller code when running.
In conclusion the embodiment of the present invention provides a kind of automatic adding method of List Controller code, device and readable deposits Storage media, first, server receive the basic class template file of user terminal uploads, and create a warehouse GIT, by basic class Template file storage obtains basic class template file corresponding warehouse address in the warehouses GIT to after in the warehouses GIT, and by storehouse Library address feeds back to user terminal, and when needing to download basic class template file, user terminal response shell scripts operation refers to It enables, creates one for storing the template directory of basic class template file, and by warehouse address by the basic class in server Template file downloads in template directory, then, instruction processing is carried out to downloading the basic class template file completed, at instruction It manages obtained code to be added under the specified directory of developing instrument, to realize that code adds.As a result, by the way that List Controller is normal The warehouses GIT that basic class template file is uploaded onto the server obtain warehouse address, and developer is facilitated to pass through this warehouse Code is downloaded to update newest block code in address, and facilitates scripting, can be realized as arranging by running shell scripts Table controller often uses the multiplexing of code, improves the efficiency of writing of similar codes as far as possible, reduces developer's workload.
It should be noted that at some as in the realization method replaced, the function of being marked in box can also be to be different from The sequence marked in attached drawing occurs.For example, two continuous boxes can essentially be basically executed in parallel, they are sometimes It can execute in the opposite order, this is depended on the functions involved.It is also noted that every in block diagram and or flow chart The combination of box in a box and block diagram and or flow chart can use function or the dedicated base of action as defined in executing It realizes, or can be realized using a combination of dedicated hardware and computer instructions in the system of hardware.
In addition, each function module in each embodiment of the present invention can integrate to form an independent portion Point, can also be modules individualism, can also two or more modules be integrated to form an independent part.
It can replace, can be realized wholly or partly by software, hardware, firmware or its arbitrary combination.When When using software realization, can entirely or partly it realize in the form of a computer program product.The computer program product Including one or more computer instructions.It is all or part of when loading on computers and executing the computer program instructions Ground is generated according to the flow or function described in the embodiment of the present invention.The computer can be all-purpose computer, special purpose computer, Computer network or other programmable devices.The computer instruction can store in a computer-readable storage medium, or Person is transmitted from a computer readable storage medium to another computer readable storage medium, for example, the computer instruction Wired (such as coaxial cable, optical fiber, digital subscriber can be passed through from a web-site, computer, server or data center Line (DSL)) or wireless (such as infrared, wireless, microwave etc.) mode to another web-site, computer, server or data Center is transmitted.The computer readable storage medium can be that any usable medium that computer can access either is wrapped The data storage devices such as server, the data center integrated containing one or more usable mediums.The usable medium can be magnetic Property medium, (for example, floppy disk, hard disk, tape), optical medium (for example, DVD) or semiconductor medium (such as solid state disk Solid State Disk (SSD)) etc.
It should be noted that herein, term " including ", " including " or its any other variant are intended to non-row Its property includes, so that the process, method, article or equipment including a series of elements includes not only those elements, and And further include the other elements being not explicitly listed, or further include for this process, method, article or equipment institute it is intrinsic Element.In the absence of more restrictions, the element limited by sentence " including one ... ", it is not excluded that including institute State in the process, method, article or equipment of element that there is also other identical elements.
It is obvious to a person skilled in the art that invention is not limited to the details of the above exemplary embodiments, Er Qie In the case of without departing substantially from spirit or essential attributes of the invention, the present invention can be realized in other specific forms.

Claims (10)

1. a kind of automatic adding method of List Controller code, which is characterized in that applied to the service communicated to connect between each other Device and user terminal, the method includes:
The server receives the basic class template file of the user terminal uploads, includes in the basic class template file Dynamic class template file and script type template file;
A warehouse GIT is created, after in the basic class template file storage to the warehouses GIT, obtains the basic class template File corresponding warehouse address in the warehouses GIT, and the warehouse address is fed back into the user terminal;
When needing to download the basic class template file, the user terminal responds shell script operating instructions, creates one Template directory for storing the basic class template file;
It will be in the basic class template file download to the template directory in the server by the warehouse address;
Instruction processing is carried out to downloading the basic class template file completed, the code that instruction is handled is added to developing instrument Specified directory under, with realize code add.
2. the automatic adding method of List Controller code according to claim 1, which is characterized in that the user terminal is rung The step of answering shell script operating instructions, creating a template directory for storing the basic class template file, including:
Whether in operating status detect shell scripts;
When detecting that the shell scripts are in operating status, false form parameter is defined;
By the false form parameter in one false form catalogue of directory creating where the shell scripts.
3. the automatic adding method of List Controller code according to claim 2, which is characterized in that the method is also wrapped It includes:
It responds shell scripts and creates instruction, create a shell script, and fixed instruction is added in the shell scripts.
4. the automatic adding method of List Controller code according to claim 1, which is characterized in that described to pass through the storehouse Library address by the basic class template file download in the server to the step in the template directory, including:
From the basic class template file searched in the server under the warehouse address directory;
It will be in the basic class template file download to the template directory of establishment that found.
5. the automatic adding method of List Controller code according to claim 1, which is characterized in that download for described pair and complete Basic class template file carry out instruction processing, the code that instruction is handled is added under the specified directory of developing instrument, With the step of realizing code addition, including:
The upper level catalogue of current shell scripts is returned, the absolute path of active user's working directory and the absolute road are obtained The absolute address of diameter;
The address of the template directory is obtained, and the address based on the template directory is in the next stage catalogue of the template directory The lower specified directory for creating a developing instrument, the exploitation work is copied to by the basic class template file in the template directory In the specified directory of tool, to realize that code adds.
6. the automatic adding method of List Controller code according to claim 1, which is characterized in that downloading completion Basic class template file carries out instruction processing, and the code that instruction is handled is added under the specified directory of developing instrument, with After the step of realizing code addition, the method further includes:
All Files under the template directory are deleted, code are removed by the upper level catalogue for returning to the template directory.
7. a kind of automatic adding method of List Controller code, which is characterized in that be applied to the user being connect with server communication Terminal, the method includes:
Basic class template file is uploaded into the server, so that the server receives the basic class template file and creates A warehouse GIT is built, obtaining the basic class template file after by the basic class template file storage to the warehouses GIT exists Corresponding warehouse address in the warehouses GIT includes dynamic class template file and script type in the basic class template file Template file;
The warehouse address that the server is sent is received, when needing to download the basic class template file, responds shell scripts Operating instruction creates a template directory for storing the basic class template file;
It will be in the basic class template file download to the template directory in the server by the warehouse address;
Instruction processing is carried out to downloading the basic class template file completed, the code that instruction is handled is added to developing instrument Specified directory under, with realize code add.
8. the automatic adding method of List Controller code according to claim 7, which is characterized in that download for described pair and complete Basic class template file carry out instruction processing, the code that instruction is handled is added under the specified directory of developing instrument, With the step of realizing code addition, including:
The upper level catalogue of current shell scripts is returned, the absolute path of active user's working directory and the absolute road are obtained The absolute address of diameter;
The address of the template directory is obtained, and the address based on the template directory is in the next stage catalogue of the template directory The lower specified directory for creating a developing instrument, the exploitation work is copied to by the basic class template file in the template directory In the specified directory of tool, to realize that code adds.
9. a kind of code automatic adding device, which is characterized in that be applied to the user terminal being connect with server communication, the dress Set including:
Uploading module, for basic class template file to be uploaded to the server, so that server reception is described basic Class template file simultaneously creates a warehouse GIT, and the base is obtained after by the basic class template file storage to the warehouses GIT This class template file corresponding warehouse address in the warehouses GIT includes dynamic class mould in the basic class template file Plate file and script type template file;
Receiving module, the warehouse address sent for receiving the server, when needing to download the basic class template file, Shell script operating instructions are responded, a template directory for storing the basic class template file is created;
Download module, for by the warehouse address by the basic class template file download in the server to the template In catalogue;
Code add module is handled instruction for carrying out instruction processing to downloading the basic class template file completed Code is added under the specified directory of developing instrument, to realize that code adds.
10. a kind of readable storage medium storing program for executing, which is characterized in that be stored with computer program, the meter in the readable storage medium storing program for executing Calculation machine program is performed the automatic adding method of List Controller code realized described in any one of claim 7-8.
CN201810386430.XA 2018-04-26 2018-04-26 Automatic adding method and device of list controller codes and readable storage medium Active CN108563440B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810386430.XA CN108563440B (en) 2018-04-26 2018-04-26 Automatic adding method and device of list controller codes and readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810386430.XA CN108563440B (en) 2018-04-26 2018-04-26 Automatic adding method and device of list controller codes and readable storage medium

Publications (2)

Publication Number Publication Date
CN108563440A true CN108563440A (en) 2018-09-21
CN108563440B CN108563440B (en) 2021-09-07

Family

ID=63536943

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810386430.XA Active CN108563440B (en) 2018-04-26 2018-04-26 Automatic adding method and device of list controller codes and readable storage medium

Country Status (1)

Country Link
CN (1) CN108563440B (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109885299A (en) * 2019-01-23 2019-06-14 平安科技(深圳)有限公司 Template processing method, device, computer equipment and storage medium in model development
CN110096272A (en) * 2019-03-19 2019-08-06 深圳壹账通智能科技有限公司 Library file processing method, device, computer equipment and storage medium
CN110442371A (en) * 2019-08-05 2019-11-12 武汉斗鱼网络科技有限公司 A kind of method, apparatus of release code, medium and computer equipment
CN111026390A (en) * 2019-11-21 2020-04-17 山东中创软件商用中间件股份有限公司 Multi-application multi-engine process template management system, method, device and storage medium
CN113050937A (en) * 2021-04-21 2021-06-29 中国工商银行股份有限公司 Front-end data processing method and device based on command line
CN113656048A (en) * 2021-08-25 2021-11-16 工银科技有限公司 Business component code installation method, tool and component code sharing system

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101403968A (en) * 2008-11-20 2009-04-08 用友软件股份有限公司 Model-driven software development method and system based on template
CN103077038A (en) * 2013-01-31 2013-05-01 北京金和软件股份有限公司 Method for dynamically generating and compiling .NET item
US20170004154A1 (en) * 2015-07-01 2017-01-05 Actifio, Inc. Integrating copy data tokens with source code repositories

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101403968A (en) * 2008-11-20 2009-04-08 用友软件股份有限公司 Model-driven software development method and system based on template
CN103077038A (en) * 2013-01-31 2013-05-01 北京金和软件股份有限公司 Method for dynamically generating and compiling .NET item
US20170004154A1 (en) * 2015-07-01 2017-01-05 Actifio, Inc. Integrating copy data tokens with source code repositories

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
SUNRIER: ""Linux下使用Shell脚本快速创建项目目录模板"", 《CSDN博客:HTTPS://BLOG.CSDN.NET/SUNRIER/ARTICLE/DETAILS/7760166》 *
ZIKZIN: ""使用Git Bash从Git上下载代码到本地以及上传代码到码云Git"", 《博客园:HTTPS://WWW.CNBLOGS.COM/BABYSBREATH/P/7274195.HTML》 *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109885299A (en) * 2019-01-23 2019-06-14 平安科技(深圳)有限公司 Template processing method, device, computer equipment and storage medium in model development
CN110096272A (en) * 2019-03-19 2019-08-06 深圳壹账通智能科技有限公司 Library file processing method, device, computer equipment and storage medium
CN110442371A (en) * 2019-08-05 2019-11-12 武汉斗鱼网络科技有限公司 A kind of method, apparatus of release code, medium and computer equipment
CN110442371B (en) * 2019-08-05 2022-08-16 武汉斗鱼网络科技有限公司 Method, device and medium for releasing codes and computer equipment
CN111026390A (en) * 2019-11-21 2020-04-17 山东中创软件商用中间件股份有限公司 Multi-application multi-engine process template management system, method, device and storage medium
CN113050937A (en) * 2021-04-21 2021-06-29 中国工商银行股份有限公司 Front-end data processing method and device based on command line
CN113656048A (en) * 2021-08-25 2021-11-16 工银科技有限公司 Business component code installation method, tool and component code sharing system

Also Published As

Publication number Publication date
CN108563440B (en) 2021-09-07

Similar Documents

Publication Publication Date Title
CN108563440A (en) The automatic adding method of List Controller code, device and readable storage medium storing program for executing
CN110389900B (en) Distributed database cluster testing method and device and storage medium
CN102819461B (en) Desktop synchronous method, device, equipment and system
US9286040B2 (en) Software builder
JP6463393B2 (en) Tenant data recovery across tenant migration
US9639558B2 (en) Image building
JP2019517043A (en) Automatic update of hybrid application
WO2021076311A1 (en) Methods and systems for integrated development environment editor support with a single code base
US20130227085A1 (en) Terminal and method for using cloud services
CN103379476A (en) Terminal and contact information updating method
CN108829430A (en) Java Web project update method and relevant apparatus based on Eclipse and Tomcat
CN103617055B (en) A kind of method, apparatus and browser for starting application program in a browser
CN104166607A (en) Data processing method and device for backup database
CN111651352B (en) Warehouse code merging method and device
CN112149035A (en) Website static resource processing method and device
US20150280996A1 (en) Cloud topology visualizations
CN113656005B (en) Application component library construction method, application component configuration method and related devices
CN111984248A (en) Page editing method and device, storage medium and electronic device
CN103475521A (en) Method and device for deploying server
CN110532016A (en) Method for edition management, method for updating edition and edition management system
CN115357198A (en) Mounting method and device of storage volume, storage medium and electronic equipment
CN114996236A (en) Data processing method, device and equipment for converged storage system and storage medium
CN108008984A (en) A kind of resource file downloading updating method and device
CN115964061A (en) Plug-in updating method and device, electronic equipment and computer readable storage medium
US20210042271A1 (en) Distributed garbage collection for dedupe file system in cloud storage bucket

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant