您的位置:首页 > 其它

git分支与主线合并流程

2017-09-12 16:17 218 查看
1.git status 查看是否为dev分支代码

2.git checkout master 检出为主线代码

3.git merge dev 合并分支代码,将当前主线分支指针指向dev

4.git pull 提交合并代码到主线

5.git push 提交本地代码到远程

6.git checkout dev_hdj 切换回分支代码

D:\BI-MIS\fs-bi-crm-report>git status

On branch dev_hdj

Your branch is up-to-date with 'origin/dev_hdj'.

nothing to commit, working directory clean

D:\BI-MIS\fs-bi-crm-report>git checkout master6.0_bug

Switched to branch 'master6.0_bug'

Your branch is ahead of 'origin/master6.0_bug' by 22 commits.

  (use "git push" to publish your local commits)

D:\BI-MIS\fs-bi-crm-report>git pull

Username for 'http://git.firstshare.cn': huodj

Password for 'http://huodj@git.firstshare.cn':

Already up-to-date.

D:\BI-MIS\fs-bi-crm-report>git status

On branch master6.0_bug

Your branch is ahead of 'origin/master6.0_bug' by 22 commits.

  (use "git push" to publish your local commits)

nothing to commit, working directory clean

D:\BI-MIS\fs-bi-crm-report>git pull

Username for 'http://git.firstshare.cn': huodj

Password for 'http://huodj@git.firstshare.cn':

Already up-to-date.

D:\BI-MIS\fs-bi-crm-report>git status

On branch master6.0_bug

Your branch is ahead of 'origin/master6.0_bug' by 22 commits.

  (use "git push" to publish your local commits)

nothing to commit, working directory clean

D:\BI-MIS\fs-bi-crm-report>git checkoout dev_hdj

git: 'checkoout' is not a git command. See 'git --help'.

Did you mean this?

        checkout

D:\BI-MIS\fs-bi-crm-report>git checkout dev_hdj

Switched to branch 'dev_hdj'

Your branch is up-to-date with 'origin/dev_hdj'.

D:\BI-MIS\fs-bi-crm-report>git pull

Username for 'http://git.firstshare.cn': huodj

Password for 'http://huodj@git.firstshare.cn':

Already up-to-date.

D:\BI-MIS\fs-bi-crm-report>git branch  -D master6.0_bug

Deleted branch master6.0_bug (was 4c47338).

D:\BI-MIS\fs-bi-crm-report>git merge dev_hdj

Updating 7dd0f4d..4c47338

Fast-forward

 fs-bi-crm-report-api/pom.xml                       |  2 +-

 fs-bi-crm-report-query/pom.xml                     |  2 +-

 .../java/com/facishare/bi/query/PgSQLExecutor.java |  2 ++

 .../java/com/facishare/bi/dto/GroupSchRunInfo.java |  3 ++-

 .../java/com/facishare/bi/mapper/SchRunMapper.java |  5 +++-

 .../bi/mapperbuilder/SchRunSqlBuilder.java         | 27 ++++++++++++++++++++++

 .../bi/report/export/ExcelReportExport.java        |  3 +++

 .../bi/report/export/XlsxReportExport.java         |  3 +++

 .../com/facishare/bi/service/SchRunService.java    |  4 +++-

 pom.xml                                            |  2 +-

 10 files changed, 47 insertions(+), 6 deletions(-)

D:\BI-MIS\fs-bi-crm-report>git status

On branch master6.0_bug

Your branch is ahead of 'origin/master6.0_bug' by 22 commits.

  (use "git push" to publish your local commits)

nothing to commit, working directory clean

D:\BI-MIS\fs-bi-crm-report>git push

warning: push.default is unset; its implicit value has changed in

Git 2.0 from 'matching' to 'simple'. To squelch this message

and maintain the traditional behavior, use:

  git config --global push.default matching

To squelch this message and adopt the new behavior now, use:

  git config --global push.default simple

When push.default is set to 'matching', git will push local branches

to the remote branches that already exist with the same name.

Since Git 2.0, Git defaults to the more conservative 'simple'

behavior, which only pushes the current branch to the corresponding

remote branch that 'git pull' uses to update the current branch.

See 'git help config' and search for 'push.default' for further information.

(the 'simple' mode was introduced in Git 1.7.11. Use the similar mode

'current' instead of 'simple' if you sometimes use older versions of Git)

Username for 'http://git.firstshare.cn': huodj

Password for 'http://huodj@git.firstshare.cn':

Total 0 (delta 0), reused 0 (delta 0)

remote:

remote: To create a merge request for master6.0_bug, visit:

remote:   http://git.firstshare.cn/bi/fs-bi-crm-report/merge_requests/new?merge_request%5Bsource_branch%5D=master6.0_bug
remote:

To http://git.firstshare.cn/bi/fs-bi-crm-report.git
   7dd0f4d..4c47338  master6.0_bug -> master6.0_bug

D:\BI-MIS\fs-bi-crm-report>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  git