CN110413309A - A kind of item code branch management method and system based on gitlab - Google Patents
A kind of item code branch management method and system based on gitlab Download PDFInfo
- Publication number
- CN110413309A CN110413309A CN201910710886.1A CN201910710886A CN110413309A CN 110413309 A CN110413309 A CN 110413309A CN 201910710886 A CN201910710886 A CN 201910710886A CN 110413309 A CN110413309 A CN 110413309A
- Authority
- CN
- China
- Prior art keywords
- branch
- exploitation
- code
- online
- version
- 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.)
- Pending
Links
- 238000007726 management method Methods 0.000 title claims abstract description 33
- 230000008439 repair process Effects 0.000 claims abstract description 20
- 238000011161 development Methods 0.000 claims abstract description 14
- 238000000034 method Methods 0.000 claims abstract description 12
- 230000004048 modification Effects 0.000 claims description 4
- 238000012986 modification Methods 0.000 claims description 4
- 230000001360 synchronised effect Effects 0.000 claims description 4
- 230000006641 stabilisation Effects 0.000 claims description 3
- 238000011105 stabilization Methods 0.000 claims description 3
- 230000006870 function Effects 0.000 description 31
- 230000008569 process Effects 0.000 description 3
- 238000012795 verification Methods 0.000 description 3
- 238000010586 diagram Methods 0.000 description 2
- 239000004744 fabric Substances 0.000 description 2
- 238000012360 testing method Methods 0.000 description 2
- SLVOKEOPLJCHCQ-SEYXRHQNSA-N [(z)-octadec-9-enyl] 2-(trimethylazaniumyl)ethyl phosphate Chemical compound CCCCCCCC\C=C/CCCCCCCCOP([O-])(=O)OCC[N+](C)(C)C SLVOKEOPLJCHCQ-SEYXRHQNSA-N 0.000 description 1
- 230000008901 benefit Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000004806 packaging method and process Methods 0.000 description 1
- 238000013519 translation Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/71—Version control; Configuration management
Abstract
The item code branch management method and system based on gitlab that the invention discloses a kind of, belong to Version Control and project management field, the technical problem to be solved in the present invention is how more effectively to carry out Git branch management, improve development efficiency, the function of avoiding not yet developing completion simultaneously is online, technical solution are as follows: 1. this method is specific as follows: exploitation branch and main split are divided into according to function phases difference when project development, exploitation branch is for developing next version i.e. for the partial code of online new function;After problem reparation succeeds and is verified, the problem of main split will repair problem, is repaired in code synchronisation to exploitation branch;Environment in version building and publication line is carried out using main split always before next online publication of version;When next version what's new, which all develops completion, to issue online, new function issued using the code of exploitation branch online.2. the system includes exploitation branch units, main split's unit and master branch units.
Description
Technical field
The present invention relates to Version Control and project management field, specifically a kind of item code based on gitlab point
Zhi Guanli method and system.
Background technique
Git is a distributed version control software, is initially created by Lin Nasituowazi, was sent out in 2005 with GPL
Cloth.Initial purpose is designed preferably to manage linux kernel exploitation.Git is initially intended only as one can be by before other
The rear end of end (such as Cogito or Stgit) packaging and develop, but git kernel was mature to can be independently used as later
Version Control.Many famous softwares all use git to carry out Version Control, including linux kernel, X.Org server and
The development process of the projects such as OLPC kernel.Till now from the initial publication on July 11st, 2005, issued 32 versions of Git
This, present version is to issue on 2 24th, 2019, and version number is 2.21.
Git is the version control tool for linux kernel exploitation.With the centralized version of CVS, Subversion one kind
Control tool is different, it uses the practice in distributed version library, does not need server software, so that it may operate version control
System so that the publication of source code with exchange extremely facilitate.Quickly, this is for sport as such as linux kernel for the speed of git
It is naturally critically important for mesh.Git it is outstanding be it merging tracking (merge tracing) ability.
Actually kernel development teams determine to start to develop and the version control system developed using git as kernel
When, the voice object for community of increasing income in the world is many, and maximum reason is git too involved and abstruse hard to understand, from the internal work machine of git
For system, really in this way.But go deep into exploitation, the normal use of git is all executed by some friendly orders, is made
Git becomes very handy.Now, more and more famous projects are developed using git come management project, such as: wine, U-boot
Deng.
As free fundamentalism project of increasing income, git does not do any permission to the browsing of version repository and modification and limits
System also can achieve limited permission by other tools and control, such as: gitosis, CodeBeamer MR.Script git's
Use scope is only applicable to Linux/Unix platform, but the use under windows platform is also increasingly mature, this is mainly attributed to
Cygwin, msysgit environment and TortoiseGit gui tool easy-to-use in this way.It is also had been added in the source code of git
Support to Cygwin and MinGW translation and compiling environment and gradually perfect, brings glad tidings for Windows user.
The realization principle of Git and other version control systems (such as CVS) have many difference, and git itself is concerned about file
Whether globality has change, but the difference of file content is lain in if most version control systems such as CVS or Subversion system
It is different.Git refusal keeps the version revision relationship of each file.Therefore it is each to check that the history of a file needs to be traversed for
History snapshot;Git implicitly handles Bulk Rename Utility, i.e., file default of the same name is its predecessor, preceding if without file of the same name
Search has the file of similar content in one version.
Git directly obtains data more like a file system in the machine, it is not necessary to be wired to host side and obtain data.Often
A developer can have the local replica of all exploitation history, and changes is copied to other from this local repository and opens
Originator.These changes are imported into as newly-increased exploitation branch, can be merged with local exploitation branch.Branch is very light
Magnitude, a branch is only the reference to a commit.
Git is developed with C language, to pursue highest performance.Git is automatically performed garbage reclamation, can also use order
Git gc--prune is called directly.
Git stores each newly created object as an individual files.It is occupied to compress memory space, packs
The many files of operation handlebar (file of heuristic similar name often has similar content) are entered in a file using Differential Compression
(packfile), and a corresponding index file is created, indicates deviant of the object in packfile.It is newly created right
As still individual files being used as to exist.Repacks operation is very time-consuming, and git can do this operation automatically during idle time.It can also
Repack is directly initiated with order git gc.Packfile and index file all use SHA-1 as verification and and as file
Name.Git fsck command does the integrity verification of verification sum.
An important tool of the Gitlab as Version Control, provides code trustship for developer, can browse through source generation
Code, the functions such as management defect and annotation, developer can access with Executive Team to warehouse, it is highly susceptible to browsing and submitted
Version and provide a file history library.Team Member can use built-in simple chat program (Wall) and be exchanged.
It, which also provides a code snippet collecting function, can easily realize code reuse, convenient for it is in the future in need when looked into
It looks for.But incorrect Git branch management still can bring it is some it is non-technical on fault, such as will be exploitation complete generation
Code publication is online, can not find before code old version etc..Therefore Git branch management how is more effectively carried out, improve exploitation
The development efficiency of personnel, while it is currently available technology technology urgently to be solved that the function that avoids not yet developing completion is online
Problem.
It is parallel that the patent document of Patent No. CN109146417A discloses a kind of single service line entry based on git
Project management method, disposes three sets of servers, is exploitation respectively, tests, on line;Git server is disposed by gitlab;It is all
Exploitation code carries out version management by git;With the disparity items of business, different branches is established respectively under same module, come
It is developed;It is carried out in exploitation server in development process;Internal debugging is carried out also by exploitation server;It needs to submit version
The project of this building is committed to progress last time version building on testing service device.The technical solution is applied to based on difference
The server of environment can not achieve according to the different phase of project development to carry out branch management and establish branch and carry out effective
Management, at the same be likely to result in not yet develop completion function it is online.
Summary of the invention
Technical assignment of the invention is to provide a kind of item code branch management method and system based on gitlab, to solve
Certainly how Git branch management is more effectively carried out, improve the development efficiency of developer, while avoided not yet exploitation and completing
The online problem of function.
Technical assignment of the invention realizes in the following manner, a kind of item code branch management side based on gitlab
Method, this method are specific as follows:
Exploitation (dev) branch and master (main) branch are divided into according to function phases difference when project development, exploitation branch uses
In developing next version i.e. for the partial code of online new function, main split is used to repair the generation of last revision function phases
Leftover problem;
After problem reparation succeeds and is verified, the problem of main split will repair problem, repairs code synchronisation to developing branch
On, guarantee that exploitation branch had not only solved last revision function phases leftover problem, but also the generation of the new function of next version can be developed
Code;
Environment in version building and publication line is carried out using main split always before the online publication of next version, avoiding will be new
The function code of exploitation is published to environment on line, maintains the stabilization of environment on line;
When next version what's new, which all develops completion, to issue online, new function is sent out using the code of exploitation branch
Cloth is online, guarantees that next version the problem will be repaired all before, also ensures the stability of online function newly developed.
Preferably, the problem of main split will repair problem by git cherry-pick order reparation code is same
It walks in exploitation branch.
More preferably, before the online publication of next version, the online publication unification for repairing problem is all incorporated by main split
Function just in exploitation will not be incorporated into master branch by the publication of master branch, guarantee.
More preferably, next version what's new all develops completion when issuing online, and exploitation branch is incorporated into
Master branch issues, and modification plug-in unit is synchronized to exploitation branch the problem of repairing problem in main split, and exploitation branch is i.e. not
The problem of before will appear, also increases new function, meets the specification of online publication.
More preferably, after the online publication of next version, the main split of last revision is deleted, only retains exploitation point
Branch, exploitation branch record spare as the program of last revision.
More preferably, after the online end-of-development of next version, new main split and exploitation are pulled again from master branch
Branch, exploitation and reparation problem branch as latest edition use.
A kind of item code branch management system based on gitlab, the system include,
Develop branch units, the code of the new function for developing next version;
Main split's unit, for repairing the problem of last revision is found;
Master branch units, for issuing, the problem of main split's unit repairs problem repairs code on-line and publication is opened
It is online to send out next version that branch units exploitation is completed.
Preferably, the problem of problem of reparation, is repaired generation by git cherry-pick order by main split's unit
Code is synchronized in exploitation branch.
Item code branch management method and system based on gitlab of the invention have the advantage that
(1), the present invention is based on timing nodes online every time to create branch, will repair bug according to different function phases
It is separated with the code of exploitation new function, improves the development efficiency of developer, and exploitation branch is separated with online branch
Afterwards, the problem that the function of not yet developing completion would not be caused online;
(2), the more flexible item code branch management of the present invention, can support the code between the different function stage
It distinguishes;
(3), the more convenient code record of the present invention retains dev branch as this exploitation after the completion of online every time
The code in stage records, and whether find when orientation problem after convenient is leftover problem;
(4), safer upper line process, conditional branch management all write on all codes in the same branch, this is just
Will lead to a problem: will may not yet be developed when online complete code also carry it is online;And use this method would not
There is this problem, does not also need developer and code is removed or annotated manually;
(5), the more stable environment code of the present invention, after having repaired bug every time, can all use git cherry-
By the code synchronisation of the reparation part bug to dev branch, this makes it possible to the codes for guaranteeing each environment to repair for pick order
This bug, so that environment is more stable.
Detailed description of the invention
The following further describes the present invention with reference to the drawings.
Attached drawing 1 is the item code branch management method flow block diagram based on gitlab;
Attached drawing 2 is project branch schematic diagram.
Specific embodiment
Referring to Figure of description and specific embodiment to a kind of item code branch management based on gitlab of the invention
Method and system are described in detail below.
Embodiment 1:
As shown in figure 1 and 2, the item code branch management method based on gitlab of invention, this method are specific as follows:
Dev branch and main branch are divided into according to function phases difference when S1, project development, under dev branch is for developing
I.e. by the partial code of online new function, main branch is used to repair leaving for last revision function phases generation and asks one version
Topic;
After S2, problem reparation succeed and be verified, the problem of main branch will repair problem, repairs code synchronisation to dev
In branch, guarantee that dev branch had not only solved last revision function phases leftover problem, but also the new function of next version can be developed
Code;
S3, environment in version building and publication line is carried out using main branch always before the online publication of next version, kept away
Exempt from for function code newly developed to be published to environment on line, maintains the stabilization of environment on line;
S4, when next version what's new all develop completion to issue online when, new function is issued using dev branch
Line guarantees that next version the problem will be repaired all before, also ensures the stability of online function newly developed.
In step S2, the problem of problem of reparation, is repaired code synchronisation by git cherry-pick order by main branch
Onto dev branch.
In step S3, before next online publication of version, the online publication unification for repairing problem is all incorporated by main branch
Function just in exploitation will not be incorporated into master branch by the publication of master branch, guarantee.
In step S4, next version what's new all develops completion when issuing online, and dev branch is incorporated into master points
Branch is to issue, and modification plug-in unit is synchronized to dev branch the problem of repairing problem in main branch, and dev branch is not in it
Preceding problem also increases new function, meets the specification of online publication.
After next online publication of version, the main branch of last revision is deleted, only retains dev branch, dev branch
Program as last revision records spare;New main branch and dev branch are pulled again from master branch simultaneously, as most
The exploitation of new version and reparation problem branch use.
Embodiment 2:
Item code branch management system based on gitlab of the invention, the system include,
Develop branch units, the code of the new function for developing next version;
Main split's unit, for repairing the problem of last revision is found;
Master branch units, for issuing, the problem of main split's unit repairs problem repairs code on-line and publication is opened
It is online to send out next version that branch units exploitation is completed.
Wherein, the problem of problem of reparation, is repaired code synchronisation by git cherry-pick order and arrived by main split's unit
It develops in branch.
Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention., rather than its limitations;To the greatest extent
Pipe present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that: its according to
So be possible to modify the technical solutions described in the foregoing embodiments, or to some or all of the technical features into
Row equivalent replacement;And these are modified or replaceed, various embodiments of the present invention technology that it does not separate the essence of the corresponding technical solution
The range of scheme.
Claims (8)
1. a kind of item code branch management method based on gitlab, which is characterized in that this method is specific as follows:
Exploitation branch and main split are divided into according to function phases difference when project development, exploitation branch is for developing next version i.e.
By the partial code of online new function, main split is used to repair the leftover problem of last revision function phases generation;
After problem reparation succeeds and is verified, the problem of main split will repair problem, is repaired in code synchronisation to exploitation branch,
Guarantee that exploitation branch had not only solved last revision function phases leftover problem, but also the code of the new function of next version can be developed;
Environment in version building and publication line is carried out using main split always before the online publication of next version, avoiding will be newly developed
Function code be published to environment on line, maintain the stabilization of environment on line;
When next version what's new, which all develops completion, to issue online, new function is issued using the code of exploitation branch
Line guarantees that next version the problem will be repaired all before, also ensures the stability of online function newly developed.
2. the item code branch management method according to claim 1 based on gitlab, which is characterized in that the master point
The problem of branch will repair problem by git cherry-pick order is repaired in code synchronisation to exploitation branch.
3. the item code branch management method according to claim 1 or 2 based on gitlab, which is characterized in that described
Before next online publication of version, the online publication unification for repairing problem is all incorporated into the publication of master branch by main split, guarantees not
Function just in exploitation can be incorporated into master branch.
4. the item code branch management method according to claim 3 based on gitlab, which is characterized in that described next
Version what's new all develops completion when issuing online, and exploitation branch is incorporated into master branch to issue, in main split
The problem of the problem of reparation problem modification plug-in unit is synchronized to exploitation branch, and exploitation branch is before being not in also increases new
Function meets the specification of online publication.
5. the item code branch management method according to claim 4 based on gitlab, which is characterized in that described next
After the online publication of version, the main split of last revision is deleted, only retains exploitation branch, develops branch as last revision
Program record it is spare.
6. the item code branch management method according to claim 5 based on gitlab, which is characterized in that described next
After the online end-of-development of version, new main split and exploitation branch, the exploitation as latest edition are pulled again from master branch
It is used with problem branch is repaired.
7. a kind of item code branch management system based on gitlab, which is characterized in that the system includes,
Develop branch units, the code of the new function for developing next version;
Main split's unit, for repairing the problem of last revision is found;
Master branch units repairs code on-line and publication exploitation point for issuing the problem of main split's unit repairs problem
Next version that Zhi Danyuan exploitation is completed is online.
8. the item code branch management system according to claim 7 based on gitlab, which is characterized in that the master point
The problem of Zhi Danyuan will repair problem by git cherry-pick order is repaired in code synchronisation to exploitation branch.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910710886.1A CN110413309A (en) | 2019-08-02 | 2019-08-02 | A kind of item code branch management method and system based on gitlab |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910710886.1A CN110413309A (en) | 2019-08-02 | 2019-08-02 | A kind of item code branch management method and system based on gitlab |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110413309A true CN110413309A (en) | 2019-11-05 |
Family
ID=68365345
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910710886.1A Pending CN110413309A (en) | 2019-08-02 | 2019-08-02 | A kind of item code branch management method and system based on gitlab |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110413309A (en) |
Cited By (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110968301A (en) * | 2019-12-17 | 2020-04-07 | 刘庆 | Code review creation method based on code version control native client and command |
CN111708747A (en) * | 2020-06-15 | 2020-09-25 | 中国航空工业集团公司西安飞行自动控制研究所 | Method for generating version tree of distributed version management document |
CN111831554A (en) * | 2020-06-09 | 2020-10-27 | 时时同云科技(成都)有限责任公司 | Code checking method and device |
CN111966390A (en) * | 2020-07-08 | 2020-11-20 | 深圳市科脉技术股份有限公司 | Project construction method, system, terminal device and storage medium |
CN112000334A (en) * | 2020-07-20 | 2020-11-27 | 北京达佳互联信息技术有限公司 | Page development method, device, server and storage medium |
CN113448614A (en) * | 2021-06-29 | 2021-09-28 | 北京金山云网络技术有限公司 | Software project code management method and device, storage medium and electronic equipment |
CN114741115A (en) * | 2022-06-09 | 2022-07-12 | 好享家舒适智能家居股份有限公司 | Data management method and system under multi-version concurrent scene |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20090300580A1 (en) * | 2007-12-20 | 2009-12-03 | Hsbc Technologies Inc. | Automated methods and systems for developing and deploying projects in parallel |
CN107678773A (en) * | 2017-09-28 | 2018-02-09 | 郑州云海信息技术有限公司 | A kind of code development based on git and testing process management method |
CN108415694A (en) * | 2018-02-28 | 2018-08-17 | 山东汇贸电子口岸有限公司 | A kind of Android agile development system and methods based on GitFlow workflows |
-
2019
- 2019-08-02 CN CN201910710886.1A patent/CN110413309A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20090300580A1 (en) * | 2007-12-20 | 2009-12-03 | Hsbc Technologies Inc. | Automated methods and systems for developing and deploying projects in parallel |
CN107678773A (en) * | 2017-09-28 | 2018-02-09 | 郑州云海信息技术有限公司 | A kind of code development based on git and testing process management method |
CN108415694A (en) * | 2018-02-28 | 2018-08-17 | 山东汇贸电子口岸有限公司 | A kind of Android agile development system and methods based on GitFlow workflows |
Cited By (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110968301A (en) * | 2019-12-17 | 2020-04-07 | 刘庆 | Code review creation method based on code version control native client and command |
CN111831554A (en) * | 2020-06-09 | 2020-10-27 | 时时同云科技(成都)有限责任公司 | Code checking method and device |
CN111831554B (en) * | 2020-06-09 | 2023-07-04 | 时时同云科技(成都)有限责任公司 | Code checking method and device |
CN111708747A (en) * | 2020-06-15 | 2020-09-25 | 中国航空工业集团公司西安飞行自动控制研究所 | Method for generating version tree of distributed version management document |
CN111966390A (en) * | 2020-07-08 | 2020-11-20 | 深圳市科脉技术股份有限公司 | Project construction method, system, terminal device and storage medium |
CN112000334A (en) * | 2020-07-20 | 2020-11-27 | 北京达佳互联信息技术有限公司 | Page development method, device, server and storage medium |
CN113448614A (en) * | 2021-06-29 | 2021-09-28 | 北京金山云网络技术有限公司 | Software project code management method and device, storage medium and electronic equipment |
CN114741115A (en) * | 2022-06-09 | 2022-07-12 | 好享家舒适智能家居股份有限公司 | Data management method and system under multi-version concurrent scene |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110413309A (en) | A kind of item code branch management method and system based on gitlab | |
US11789715B2 (en) | Systems and methods for transformation of reporting schema | |
US8024305B2 (en) | Updating a data warehouse schema based on changes in an observation model | |
US8515799B2 (en) | Constructing change plans from component interactions | |
US9304764B2 (en) | Automated merging in a software development environment | |
US7984426B2 (en) | Graphical representation of dependencies between changes of source code | |
US8037471B2 (en) | Systems and methods for constructing relationship specifications from component interactions | |
CA2723933A1 (en) | Methods and systems for developing, debugging, and executing data integration applications | |
US20120036497A1 (en) | Integrity check while committing changes from an integrated development environment to a source code control system | |
CN109903180A (en) | A kind of substation secondary peace arranges Information Management System | |
Demuth et al. | Efficient detection of inconsistencies in a multi-developer engineering environment | |
CN106951593B (en) | Method and device for generating configuration file of protection measurement and control device | |
CN111290738A (en) | Resource processing method, device and equipment of application program and storage medium | |
Kuryazov et al. | Representing model differences by delta operations | |
CN107885527A (en) | A kind of code revision method and device of test system | |
US20150033213A1 (en) | Compiling method, storage medium and compiling apparatus | |
Vedros et al. | Enhancement of Industry Legacy Probabilistic Risk Assessment Methods and Tools | |
US8949819B2 (en) | Rationalizing functions to identify re-usable services | |
CN117492721B (en) | General rapid development method applied to building digital information system | |
US20090177705A1 (en) | System and method for using generic utilities to perform database utilities on mainframe operated DB2 databases | |
Lindsay et al. | NEAMS-Multiphysics MOOSE End Year Framework Activities FY20 | |
Kelly et al. | Managing data-based systems across releases using historical data dictionaries | |
JP2017091027A (en) | System development support system | |
CN117785698A (en) | Software test case method and device, electronic equipment and storage medium | |
CN116185793A (en) | Point embedding method, point embedding device, computer readable storage medium and electronic equipment |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20191105 |
|
RJ01 | Rejection of invention patent application after publication |