Git advanced course _from bilibili part2

Git advanced course owed 200 minutes of course be watching

P11 local and remote conflict

1, push / pull will trigger changes in the local origin / master pointer, commit will trigger changes in the local master pointer

2, if the situation remotely look at, you can see it with the git remote show, the lowest local out of date

3, asking for the moon is fast forward

 

Conflict demo

1, two people change the same file on the same line, that inevitable conflict

2, with the general point, without stars

 

3, reported conflict

 

 

4, generally is the case, you and others conflict, you change the time to pull over and ask someone else, modified to look like they want after the git add, git commit on it

5, after git fetch, you branch on behind the origin / master of

 

 6, delete: 8,10d

 

P12 GitK and Gui

1. Here are some graphic tools, graphics tools with a lot of our own has two, one is the git gui here, the other one is gitk

 

2, so you can start

 

3, look at the remote branch LOG several writing, all exactly the same

git log origin/master
git log remotes/origin/master
git log refs/remotes/origin/master

 

 

P13 branch associated local and remote operation

 

1, the remote branch is no way to direct perception

2, Joe Smith has a distal end, a distal end you know how local it have a Joe Smith? Because you remember Joe Smith inside the brain of this man, you may remember inside the brain and the distal end is not the same

Local -> remote

Remote -> Local

 

P14 and the operation of the local branch tag github

Delete local and remote branch

 

 

 

 

 

Invalid perception distal branch

 

 

 

 

1, to sense the distal end by the local refs

2, to understand what you can, another way associated with the establishment of the distal

 

To the command from the alias

 

Simple and complex label label label

 

 

1, the push label

 

2, delete the label is actually the same, pushing an empty tag up

 

1,push,直接写git push是不会推送标签到远程的,必须写全,pull得话是报喜不报忧,新增的时候能感知,删除的时候不感知

 

P15 Git gc 压缩文件

1,这个命令跑完了之后,refs 文件夹就空了,去哪了呢?

 

2,压缩之后他把目录里边所有的东西,拉过来一次性放到了一个文件里面

 

3,笔记

 

 

 

 

P20 git rebase变基操作 

1,变基就是把根部给变了

2,cherry pick是在master,把下面的拿上来,而rebase操作点不一样,是在下面直接变基去上面,从下往上移动

 

 

 

3,rebase之后之前的两个点,就被遗忘了

4,rebase有三个常见的操作,在讲操作之前,我们先来看看他的冲突问题,rebase也会冲突

5,rebase改变很大的,不要推送到远端,也不再在master上弄

 

6,模拟rebase冲突

模拟rebase冲突 -忽略  skip的场景

7,

8,

9

 

10

 

模拟rebase冲突   continue的场景

1,这个解决冲突,就是拿出来这个文件,改成自己想要的样子,然后git add 告诉他冲突已经解决了

2,第一次冲突解决完了之后,我们还有第二次冲突

3,从下往上变基的时候, sha1值会变,通过日志也能看到

 

 

P23 Gitlab配置和管理

centos6和centos7安装配置的不同

 

安装配置gitlab

 

 

Guess you like

Origin www.cnblogs.com/lisa-blog/p/12349590.html