로컬 지점, 로컬 추적 지점, 원격 지점 및 원격 추적 지점의 차이점은 무엇입니까?
저는 Git를 사용하기 시작한 지 얼마 되지 않아 서로 다른 지점들 사이에서 혼란을 겪었습니다.다음 지점 유형이 무엇인지 아는 것을 도와줄 수 있는 사람이 있습니까?
- 지방 지부
- 로컬 추적 지점
- 멀리 떨어진 가지들
- 원격 추적 지점
그들 사이의 차이점은 무엇입니까?그리고 그들은 서로 어떻게 일합니까?
간단한 데모 코드가 정말 도움이 될 것 같습니다.
긴 대답은 이렇습니다.
원격:
Git를 공동으로 사용하는 경우 다른 컴퓨터 또는 위치와 커밋을 동기화해야 합니다.Git의 용어로 각 시스템 또는 위치는 원격이라고 하며, 각 시스템은 하나 이상의 분기를 가질 수 있습니다.대부분의 경우, 당신은 단지 하나의 이름을 갖게 될 것입니다.origin
모든 원격을 나열하려면 다음을 실행합니다.git remote
:
$ git remote
bitbucket
origin
하려면 를 실행하십시오.git remote -v
:
$ git remote -v
bitbucket git@bitbucket.org:flimm/example.git (fetch)
bitbucket git@bitbucket.org:flimm/example.git (push)
origin git@github.com:Flimm/example.git (fetch)
origin git@github.com:Flimm/example.git (push)
각 원격에는 다음과 같은 디렉토리가 있습니다..git/refs/remotes/
:
$ ls -F .git/refs/remotes/
bitbucket/ origin/
컴퓨터의 분기:
TLDR: 로컬 컴퓨터에는 로컬 비추적 분기, 로컬 추적 분기, 원격 추적 분기의 세 가지 유형의 분기가 있습니다.원격 컴퓨터에서는 한 가지 유형의 분기만 사용할 수 있습니다.
로컬 분기
를 실행합니다.git branch
:
$ git branch
master
new-feature
각 로컬 지점에는 다음과 같은 파일이 있습니다..git/refs/heads/
:
$ ls -F .git/refs/heads/
master new-feature
컴퓨터에는 로컬 분기를 추적하지 않는 것과 로컬 분기를 추적하는 것의 두 가지 유형이 있습니다.
1.1 추적하지 않는 로컬 지점
추적하지 않는 로컬 분기는 다른 분기와 연결되지 않습니다.를실하여하만다듭니나를을 실행하여 .git branch <branchname>
.
1.2. 로컬 지점 추적
로컬 분기 추적은 일반적으로 원격 추적 분기인 다른 분기와 연결됩니다.를실하여하만다듭니나를을 실행하여 .git branch --track <branchname> [<start-point>]
.
를여▁branches▁using▁you를 사용하여 어떤 로컬 지점이 볼 수 .git branch -vv
:
$ git branch -vv
master b31f87c85 [origin/master] Example commit message
new-feature b760e04ed Another example commit message
명령어의 브랜치가 "" " " "임을 알 수 .master
는 원격 분기를 하고 있습니다.origin/master
그리고 지역 지부.new-feature
아무 것도 추적하지 않습니다.
어떤 분기가 분기를 추적하는지 확인하는 또 다른 방법은.git/config
.
로컬 분기를 추적하는 것은 유용합니다.그들은 당신이 뛰도록 허락합니다.git pull
그리고.git push
사용할 업스트림 분기를 지정하지 않은 상태로 유지됩니다.분기가 다른 분기를 추적하도록 설정되지 않은 경우 다음과 같은 오류가 표시됩니다.
$ git checkout new-feature
$ git pull
There is no tracking information for the current branch.
Please specify which branch you want to merge with.
See git-pull(1) for details
git pull <remote> <branch>
If you wish to set tracking information for this branch you can do so with:
git branch --set-upstream new-feature <remote>/<branch>
원격으로 분기 추적(아직 컴퓨터에 있음)
를 실행하십시오.git branch -r
:
$ git branch -r
bitbucket/master
origin/master
origin/new-branch
원격 에는 각원추지다같음은있파다습니일이과점 아래에 파일이 ..git/refs/remotes/<remote>/
:
$ tree -F .git/refs/remotes/
.git/refs/remotes/
├── bitbucket/
│ └── master
└── origin/
├── master
└── new-branch
원격 추적 분기를 원격 시스템에 포함된 내용에 대한 로컬 캐시로 생각합니다.은 다을사추분업데있수다습니를 사용하여 할 수 .git fetch
그렇고요.git pull
뒤에서 사용합니다.
원격 추적 분기에 대한 모든 데이터는 캐시와 같이 컴퓨터에 로컬로 저장되지만 로컬 분기라고는 할 수 없습니다. (적어도, 그렇게 부르지는 않겠습니다!)그것은 단지 원격 추적 지점이라고 불립니다.
원격 시스템의 분기:
시스템의 를 볼 수 .git remote show <remote>
:
$ git remote show origin
* remote origin
Fetch URL: git@github.com:Flimm/example.git
Push URL: git@github.com:Flimm/example.git
HEAD branch: master
Remote branches:
io-socket-ip new (next fetch will store in remotes/origin)
master tracked
new-branch tracked
Local ref configured for 'git pull':
master merges with remote master
new-branch merges with remote new-branch
Local ref configured for 'git push':
master pushes to master (up to date)
new-branch pushes to new-branch (fast-forwardable)
것이.git remote
명령은 네트워크를 통해 원격 시스템의 분기에 대해 쿼리합니다.컴퓨터에서 . 로컬 추적분기업않습다지니하트를 사용합니다.git fetch
또는git pull
그것 때문에
출력에서 "원격 분기"라는 제목 아래에서 원격 시스템에 존재하는 모든 분기를 볼 수 있습니다("stale"로 표시된 선은 무시).
수 ▁branches▁if▁machine다▁in▁you▁remoteitory▁have니있▁and▁a▁at▁look▁all▁could수▁repos▁you▁the원,의 모든 분기를 확인할 수 있습니다.refs/heads/
.
치트 시트:
추적 여부에 관계없이 로컬 분기를 안전하게 삭제하려면 다음과 같이 하십시오.
git branch -d <branchname>
추적 여부에 관계없이 로컬 분기를 강제로 삭제하려면:
git branch -D <branchname>
원격 추적 분기를 삭제하는 방법
git branch -rd <remote>/<branchname>
새 로컬 비추적 분기를 만드는 방법
git branch <branchname> [<start-point>]
( "" "" "" "" "" "" "" "" "" "" " "" " " " " " " ") "
<start-point>
지정되었으며 다음과 같은 원격 감지 분기입니다.origin/foobar
다음에 그음에다.--track
플래그가 자동으로 포함됨)git branch --track <branchname> [<start-point]
예:
git branch --track hello-kitty origin/hello-kitty
원격 컴퓨터에서 분기를 삭제하는 방법
git push --delete <remote> <branchname>
원격 시스템에 해당 분기가 더 이상 존재하지 않는 오래된 원격 추적 분기를 모두 삭제하려면 다음과 같이 하십시오.
git remote prune <remote>
일부 명령에서는 다음을 사용할 수 있습니다.<remote>/<branch>
기타명령,<remote> <branch>
예:git branch origin/hello-kitty
그리고.git push --delete origin hello-kitty
.
임의로 보일 수도 있지만 슬래시를 사용할 때와 공백을 사용할 때를 기억하는 간단한 방법이 있습니다.슬래시를 사용할 때는 자신의 컴퓨터에 있는 원격 추적 분기를 말하는 반면, 공간을 사용할 때는 네트워크를 통해 원격 컴퓨터에 있는 분기를 처리합니다.
로컬 분기는 사용자(로컬 사용자)만 볼 수 있는 분기입니다.로컬 컴퓨터에만 존재합니다.
git branch myNewBranch # Create local branch named "myNewBranch"
원격 분기는 원격 위치의 분기입니다(대부분의 경우).origin
branch )를 .myNewBranch
origin
이제 다른 사용자가 추적할 수 있습니다.
git push -u origin myNewBranch # Pushes your newly created local branch "myNewBranch"
# to the remote "origin".
# So now a new branch named "myNewBranch" is
# created on the remote machine named "origin"
원격 추적 분기는 원격 분기의 로컬 복사본입니다.언제myNewBranch
푸시됨origin
인 위의명령사여, 적추분가기하용원origin/myNewBranch
컴퓨터에 생성됩니다. 이원추분는원분격추적다를 합니다.myNewBranch
origin
다음을 사용하여 원격 추적 분기를 원격 분기와 동기화되도록 업데이트할 수 있습니다.git fetch
또는git pull
.
git pull origin myNewBranch # Pulls new commits from branch "myNewBranch"
# on remote "origin" into remote tracking
# branch on your machine "origin/myNewBranch".
# Here "origin/myNewBranch" is your copy of
# "myNewBranch" on "origin"
로컬 추적 분기는 다른 분기를 추적하는 로컬 분기입니다.따라서 다른 분기에서 커밋을 푸시/풀할 수 있습니다.대부분의 경우 로컬 추적 분기는 원격 추적 분기를 추적합니다.로컬 분기를 다음으로 푸시할 때origin
사용git push
로합니다로 합니다.-u
은 브랜치 션(으)로 합니다.myNewBranch
분기를 합니다.origin/myNewBranch
은 이은사필니다합요에를 할 때 합니다.git push
그리고.git pull
밀어넣거나 끌어낼 업스트림을 지정하지 않은 상태로 이동합니다.
git checkout myNewBranch # Switch to myNewBranch
git pull # Updates remote tracking branch "origin/myNewBranch"
# to be in sync with the remote branch "myNewBranch"
# on "origin".
# Pulls these new commits from "origin/myNewBranch"
# to local branch "myNewBranch which you just switched to.
로컬 지점:
작업할 수 있고 커밋을 추가할 수 있는 시스템의 분기입니다.은 이 을 다음분수있다습니나와 함께 할 수 .git branch
.
로컬 지점(추적 포함):
원격 분기에 해당하도록 구성된 일반 로컬 분기입니다.이는 다음과 같은 이점이 있습니다.git pull
그리고.git push
저장소 및 분기 이름을 지정할 필요가 없습니다.추적은 또한 원인이 됩니다.git status
원격으로 지점이 앞에 있거나 뒤에 있을 때 알려줍니다.
원격 지점:
일반적으로 GitHub 등과 같은 서버에 있는 원격 저장소의 분기입니다.
원격 추적 지점:
원격 분기의 로컬 복사본입니다.이 분기는 편집해서는 안 됩니다.원격 분기의 현재 상태를 추적하는 것이 목적입니다.은 원격추적분다통볼수있으로 볼 수 .git branch -r
그리고 전형적으로 다음과 같은 것처럼 보입니다.origin/master
(repo 이름 뒤에 슬래시가 오고 지점 이름이 옵니다). 중입니다.git fetch
원격 추적 분기를 업데이트하여 해당 원격 분기의 상태를 반영합니다.
git branch -avv
컴퓨터에 있는 분기, 원격에 있는 분기 및 각 분기의 최신 커밋에 대한 간략한 개요를 표시하는 데 사용되는 개인적인 즐겨찾기입니다. 그-a
part는 모든 분기(원격 및 로컬)를 표시하도록 지정합니다. 그v
의 끝은 verbose(마지막 커밋 해시 및 메시지를 표시함)를 나타냅니다. @@Flimm을 지적해 주셔서 감사합니다.v
에서는 어떤 로컬 분기가 어떤 원격을 추적하고 있는지에 대한 정보를 추가합니다.
개요
TL;DR - 알아야 할 내용으로 건너뛰도록 구성되어 있습니다.
아래에서 다룰 내용은 다음과 같습니다.
- 빠른 개요 - 4가지 유형의 분기는 무엇이며 어디에서 찾을 수 있는지 설명합니다.
- 짧은 용어집 - 분기와 관련된 기본 원칙 및 용어
- 조사 - 로컬 및 원격 지점을 검사하는 방법
- 관련 파일 - 구성 파일
- 구성 - 분기 구성을 보고 설정하는 방법
- Collaborating - 원격 지사 사용 방법
간단한 개요
로컬 지점은 로컬 저장소에서 헤드를 가리키는 이름입니다.
원격 분기는 원격 저장소의 헤드를 나타내는 이름입니다.
단순 분기는 한 가지를 참조하는 로컬 이름입니다.
- 그것은 직접적으로 지역 수장을 가리킵니다. (즉, 특정한 약속; 증가하는 팁)
추적 분기는 두 가지를 참조하는 로컬 이름입니다.
- 직접적으로 지역 책임자를 가리킵니다(즉, 특정 책임자; 증가하는 팁).
- 원격 저장소의 두 번째 분기를 상징적으로 가리킵니다.
두 가지 유형의 추적 분기가 있습니다.
local - 분기가 로컬 헤드를 가리킵니다.
이를 로컬 추적 분기라고 합니다(아래 자세한 내용).remote - 분기가 원격 헤드의 로컬 복사본을 가리킵니다.
이를 원격 추적 분기라고 합니다(아래 자세한 내용).
다음은 4가지 유형의 분기로, 분기가 표시되는 위치와 분기 매핑 방법입니다.
WHERE ---BRANCH TYPE-------- --REFERENCE TARGETS-------
--------------------------------------------------------------
Remote simple branch -----------> remote head (a commit ID)
--------------------------------------------------------------
Local simple branch -----------> local head (a commit ID)
Local local tracking-branch --> local head (a commit ID1)
--> Remote-name/branch-name
Local remote tracking-branch --> local head (a commit ID2)
--> Remote-name/branch-name
--------------------------------------------------------------
짧은 용어집
원격 및 지점이라는 용어가 오버로드된 것 같습니다.
그리고 추적 지점이라는 단어는 특히 혼란스럽습니다. 추적 지점과 실제로는 다르기 때문입니다.
'a snapshot' - A recording of the state of one or more files
and their contents at a given moment in time.
'a commit' - A container holding one snapshot, the date and
time it was recorded, who recorded it, and a
comment to say what it's all about.
'a repository' - A repository of commits, organized so we can
look thru them, going backwards in time.
Much like photos added in sequence to a photo
album book, to record our own history, each commit
contains a snapshot of the exact state of our
project at a given moment in time.
It is used to be able to look backwards in time to
how it was at any recorded previous time.
'Remote' - (Upper case) Short for 'a named remote repository'
(of commits, of snapshots)
'remote' - (Lower case) Located on another git repository
'local' - Located on your local git repository
'a head' - A specific young commit, with no children yet of
it's own (i.e. no other commits yet pointing to it),
but which may link backwards in time to one or more
of it's natural parents.
Also called a growing tip.
Initially set to a <start-point>.
'a branch' - A symbolic name (i.e. an identifier) pointing
to one specific head, and possibly, depending on
the branch type, also pointing to a remote branch.
The term 'branch' can also refer to a specific
linked list of multiple commits (plural), starting
from the growing tip (or most recent baby), and
linking offspring to their parent(s) backwards in
time.
'tracks' - As we move forward, tracks are what we leave behind.
'tracked' - To be followed, as in, to come afterwards, or after
the fact, by way of the evidence left behind, of the
a state of being of the thing being tracked, as it
moves forwards in time.
'tracking' - The process of capturing and organizing snapshots of
our project so we can later look backwards in time
to find how it previously was.
'tracking-branch' - This term is somewhat redundant, and confusing,
but does have a specific, important meaning.
I have deliberately added the hyphen, because this
term does NOT mean simply 'tracking branch'. (Grab
your aspirin, and a cold pack for your head, lol.)
Because all branches in git are used for, and only
used for, tracking your project, therefore it could
be said that ALL branches are actually
'tracking-branches', but we don't call them that.
Instead we call them, simply 'branches'.
But then what is a 'tracking-branch'?
TL;DR A 'tracking-branch' is a local name that points to
two branches at the same time.
So when you read 'tracking-branch, it might be
helpful to instead think: 'branch-pair'.
(Normal branches only point to one thing, the
head, which is the commit at a growing tip.
And they do not have any symbolic pointers.)
1) The first branch a 'tracking-branch' points to
is the same as for any other branch: a local head,
(i.e. a young commit in our local repository without
any children.) This is where a tracking-branch
keeps a full local copy of a remote branch.
Note that it doesn't necessiarialy hold a full
duplicate copy of the entire second, remote
repository. If you have cloned the remote
repository then you already have most, if not all
of their commits in your own local repository.
2) The second branch a 'tracking-branch' points to
is a branch on a remote repository.
It does this with a <remote-name>/<branch-name>.
The 'remote-name' is used to find the URL to the
remote repository. See `git remote -v`.
Why point to two branches?
This is to be able to operate on two heads at the
same time, like to copy commits from one head to
the other as `git fetch` and `git push` does.
We have two types of 'tracking-branches' (both on
our local repository):
'local tracking-branches',
with a simple branch name, and
'remote tracking-branches',
with a path-style branch name.
See `git branch -avv`. For example:
첫 번째 두 줄 출력은 로컬 추적 분기입니다.별표(*) 접두사
master
는 것을 알 수 있습니다.master
는 현재 기본 분기(즉, 작업 영역에 체크아웃된 항목)입니다.BTW, 그 이름은master
는 의줄말임의 줄임말입니다.refs/heads/master
.세 번째 라인 출력은 단순한 로컬 분기입니다.
4번째 라인 출력은 분기가 아니라 기본 원격 추적 분기를 가리키는 두 번째 로컬 헤드(일반 로컬 헤드에 추가) 또는 이 예에서 다음 분기 중 하나입니다.사용하다
git remote set-head <remote-name> <remote tracking-branch name>
설정합니다. (참고: 이 또한 반환된 HEAD와 동일하지 않습니다.git remote show <remote-name>
된 값입니다를 참조하십시오.마지막 두 줄 출력은 원격 추적 분기입니다.
모든 분기는 커밋 ID(16진수)를 참조합니다. remotes/origin/HEAD
지점이 아니기 때문에 이것이 없습니다.
두두이 이름의 원격 이름은 또한처두마이두줄원분대격기의참있가기한다습지니고인조도적호이에은름원격경은우음줄막지과이▁also있(다습니가고이▁reference▁also▁and▁to▁ain▁on▁the은름▁have▁symbolic).origin
).
여기 '마스터'가 우리 지역의 작업 지점입니다.그리고.remotes/origin/master
는 이이지분로복다니라는 입니다.master
)git fetch
,git clone
또는git pull
에서 ) 우리가부원격에서는르▁)서원에.origin
.
(BTW,origin
으로, 원래 복원저기이다본니름입의장입니다.git clone
명령.)
So our 'remote tracking-branches' are not remote
branches, on a remote repository, but rather are
local branches, which have a local head of their
own, pointing to a local commit, and also at the
same time symbolically pointing, to a remote
branch.
With `git branch -avv`, notice how two branches can
point to origin/remote:
* the first being the 'local-tracking-branch'
with the name 'master', and with the
'[origin/master]' extra clause, and
* the second being the 'remote-tracking-branch'
with the name 'origin/master'.
NOTE: Though they point to the same remote branch,
the local commit head is not always the same!
Thus they are actually two different branches.
The 'local-tracking-branch' is our working branch,
and the 'remote-tracking-branch' is a copy of the
remote's branch that we cloned from or fetched to
update.
조사
원격
git remote # List names of known Remotes
git remote -v # List names of known Remotes and
# show the 2 URL's pointing to them
#
# See '[remote "<names>"]' in
# $ cat .git/config
원격 분기(원격 저장소에 위치)
git remote show <remote-name> # Download and view
# a specific Remote's info.
# for example, let's download the information for
# two remotes named origin and upstream:
선행 별표(*)는 주어진 원격에서 데이터의 시작을 표시하는 글머리 기호입니다.우리는 두 개의 리모트에서 다운로드를 요청했고, 그래서 우리는 두 개의 총알을 가지고 있습니다.
첫 번째 라인 출력에는 'remote'라는 단어가 앞에 붙은 리모컨의 이름이 표시됩니다.
두 번째와 세 번째 행은 원격 이름에 대해 로컬로 구성된 가져오기 및 푸시 URL을 보고합니다.
origin
에서도 할 수 .git remote -v
.네 번째 줄은 원격 저장소에서 HEAD를 보고합니다.이 HEAD는 설정할 수 없습니다.로컬 HEAD와 동일하지도 않고 원격의 로컬 판독치도 아닙니다.
git branch -avv
6번째 줄에서 시작하는 것은 원격 저장소가 소유한 분기 목록입니다.
원격 지점: 추적된 마스터 업데이트 추적
그리고 나서 토렉은 남은 대사에 대해 이렇게 말합니다.
Git 리모트 쇼가 하는 모든 것은 [리모트]를 불러오는 것, 사용하는 것입니다.
git ls-remote
인터넷 전화를 통해, 그리고 그들의 언급을 당신의 언급과 비교하여 무엇인지 추측합니다.git fetch
그리고.git push
될 것 ( 당신이 해결기할사수다있니습. (하는경우용로으를과반)를 한다면)git pull
그것은 단지 도망치는 것을 의미합니다.git fetch
그 다음에 달려라git merge
.git remote show
명령어는 그것이 무엇을 할 것인지 추측하려고 시도합니다.)
LOCAL Branchs(로컬 저장소에 위치)
git branch -avv # Show ALL 'local branches', verbosely; (3 types):
git branch -rv # -- type 1 -------------------------------------
# Show ONLY 'local branches' that point to
# 'remote branches' (-r = remote; -v = verbose)
#
# This lists your 'Remote tracking branches'!
# From: $ tree .git/refs/remotes/*
#
# They allow us to move snapshots between
# repositories, and to keep a copy of
# Remote's branches locally.
git branch -vv # -- types 2 and 3 ------------------------------
# Show ONLY 'local branches', that point to local
# things, but his includes two different types of
# branches mixed together, for example:
* master de430b6 [origin/master] <comment describing this branch>
updates 3c40299 [origin/updates] <comment describing this branch>
foo de430b6 <comment describing this branch>
처음 두 지점의 이름은 다음과 같습니다.master
그리고.updates
(위), 둘 다 커밋 번호 뒤에 추가 필드가 있습니다. '라는 분기의 이는 'master'입니다.[origin/master]
.
이는 이 두 분기가 일반적인 로컬 분기가 아니라 로컬 추적 분기임을 나타냅니다.위의 '원격 추적 분기'와 마찬가지로, 원격 분기를 상징적으로 가리키기도 합니다.따라서master
이 경우, 로컬 저장소의 분기 헤드를 가리킬 뿐만 아니라,origin/master
원격 저장소에 있습니다.
이러한 추가 필드는 .git/config의 매개 변수로 설정됩니다.
적으로대조,,foo
여기 단순하고 정상적인 가지가 있습니다. 즉, 비연속적입니다.
관련 파일
cat .git/config # '[branch "<names>"]' are local
# tracking branches
ls -F .git/refs/heads/* # 'Local' branch names & heads:
# both tracking and non-tracking
ls .git/refs/remotes/<remote-name>/* # 'Remote' tracking branch names & heads
배열
사용하여 만들기git branch,
git checkout -b
저복제여로 git clone
합니다..git/config
또는 다음과 같은 기능을 사용:
리모콘
Git로 합니다.git clone
.
git remote add
이름을 합니다.git remote rename
git remote remove
git remote prune
합니다.
다음을 사용하여 속성 설정:
git set-url
URL을 URL의 .git set-url --add
URL의 합니다.git set-url --delete
합니다. URL을 삭제합니다.git set-branches
추적된 분기 집합 변경git set-branches --add
중인git set-head
기본 원격 분기(즉, 원격의 HEAD)를 설정합니다.git set-head --auto
원격의 합니다.git set-head --delete
기본 원격 분기(즉, 원격의 HEAD)를 삭제합니다.
나뭇가지
git branch [--set-upstream | --track | --no-track] [-l] [-f] <NewBranchName> [<start-point>] # create branch (start point defaults to HEAD)
git branch (--set-upstream-to=<upstream-branch> | -u <upstream-branch>) [<BranchName>] # link to upstream branch
git branch --unset-upstream [<BranchName>] # unlink to upstream branch
git branch --edit-description [<BranchName>] # edit branch description
git branch (-m | -- move | -M) [<oldBranchName>] <newBranchName> # rename (move) branch; -M = force
git branch (-d | -D) [-r] <BranchName>... # delete branch
협업
에서는 "" " " " "일 때"git clone
자동으로 원격 및 추적 기능을 설정합니다.그러나 이 기능을 사용하지 않도록 설정하거나 작동 방식을 변경하는 구성 설정이 있습니다.
팁 옵션 사용git fetch
그리고.git push
당신이 그것을 하기 전에 무슨 일이 일어날지 보기 위해.
사용(통화를 통해 가능)git pull
를 클릭하여 원격의 커밋 로컬 복사본을 업데이트하여 최신 정보를 제공합니다.
를 포함하지 않으면 기본값이 사용됩니다.는 에기본무수있확에서 확인할 수 ..git/config
에 시대에fetch=
의 [remote "<remote-name>"]
다음과 같이 표시될 수 있습니다.
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
은 문은입니다.[+]?<source>:<destination>
즉, 참조(일반적으로 커밋 및 태그)를 다음에서 가져오는 것입니다..git/refs/heads/*
로, 합니다..git/refs/remotes/origin/*
우리의 추적 장치인 지점들.좋아요, 에! BTW, '+'는 이것이 빠르게 진행되지 않더라도 업데이트하라고 말합니다.
쓰기 권한이 있는 원격 리포지토리로 로컬 커밋을 보내는 데 사용합니다.
제가 이 모든 것을 맞았으면 좋겠습니다.
언급URL : https://stackoverflow.com/questions/16408300/what-are-the-differences-between-local-branch-local-tracking-branch-remote-bra
'programing' 카테고리의 다른 글
홈브루에서 python@2를 다시 설치하는 방법은 무엇입니까? (0) | 2023.06.23 |
---|---|
Oracle SQL용 파서 (0) | 2023.06.23 |
Visual Studio 2019 프로세스가 종료되지 않음, NodeJS 문제 (0) | 2023.06.23 |
SQL Server - 현재 사용자 이름 (0) | 2023.06.23 |
구성 요소는 Angular에서 두 모듈 선언의 일부입니다. (0) | 2023.06.23 |