IT

현재 분기가 pull에 대해 구성되지 않았습니다. 구성에서 키 branch.master.merge에 대한 값이 없습니다.

lottoking 2020. 5. 31. 10:39
반응형

현재 분기가 pull에 대해 구성되지 않았습니다. 구성에서 키 branch.master.merge에 대한 값이 없습니다.


Egit team> pull을 사용하여 원격 저장소에서 가져 오려고하면이 오류가 발생합니다.

현재 분기가 pull에 대해 구성되지 않았습니다. 구성에서 키 branch.master.merge에 대한 값이 없습니다.


로컬 마스터 분기가 원격 마스터 분기를 추적하도록 설정되어 있지 않습니다.

당신이 할 수있는 git pull origin master당신이 끌어하고자하는 명시 적 분기를 자식에게 또는 당신은 당신의 .git / 설정이 추가 :

[branch "master"]
  remote = origin
  merge = refs/heads/master

처음으로 마스터로 밀면 -u스위치 ( git push -u origin master)를 추가하십시오 . 모든 것이 자동으로 설정됩니다.


@ Michał Szajbe의 대답은 문제에 대한 해결책입니다. 문제의 이클립스 키는 egit "작업 디렉토리"에서 빌드됩니다. 이 문제가 발생하면 해당 작업 디렉토리에서 .git 디렉토리를 찾고 텍스트 편집기로 Michal 설명 섹션을 추가하여 .git / config 파일을 편집하십시오. 이것은 처음에는 처음으로 초기화하고 초기화되지 않은 리모컨으로 푸시하여 마스터 분기를 만드는 경우에 대한 표준 작업입니다. 이 경우 명령 줄 git에서도 git pull을 수행하기 위해 수동 편집을 수행하지 않는 방법을 찾지 못했습니다.

편집을 저장 한 후 egit "Git Repositories"퍼스펙티브에서 git repo를 마우스 오른쪽 버튼으로 클릭하고 속성을 선택하면이 키 섹션이 생성되었거나 구성 파일에서 읽은 것 같습니다. 마스터 대 로컬 마스터 git pull은 앞으로 예상대로 작동합니다.

여기에 이미지 설명을 입력하십시오

이 키와 값을 직접 입력 할 수는 있지만 Michal이 보여주는 것을 복사하여 붙여 넣는 것이 훨씬 빠르고 안전합니다. 실제로 속성 편집기를 통해 수동으로 키를 추가하려고 시도하지 않았 으며이 방법이 작동한다는 것을 알기 때문에 egit이 단순히 로컬 git repo를 호출하기 때문에 의미가 있습니다.

또한 Flex 및 Eclipse 및 egit 기반으로 빌드 된 Flexbuilder 편집기를 사용하는 일부 직원을 지원하고 있습니다. 이 지침은 그들과 똑같이 관련이 있습니다.


Eclipse에서이 문제를 해결하려면 Windows 메뉴를 열고 Show View / Other / Git Repositories를 선택하십시오 .

힘내 저장소 탭에서 :

  • 지역 저장소를 확장하십시오
  • Remote를 마우스 오른쪽 버튼으로 클릭하십시오
  • 원격 생성 ...을 클릭하십시오 .
  • 원격 이름 = 출발지
  • IRI 옆에 있는 변경 버튼을 누릅니다.
  • CTRLSPACEURI에서 +
  • 원격 위치를 선택하십시오
  • 마침을 누르 십시오
  • 를 눌러 저장하고 푸시

다시 Git Repositories 탭에서

  • 원점을 마우스 오른쪽 버튼으로 클릭
  • 가져 오기 구성 ...을 선택하십시오 .
  • Ref 맵핑에서 편집 (고급)을 누릅니다 .
  • 모든 지점 추가 스펙을 누르 십시오.
  • 선택 강제 업데이트 확인란을
  • 마침을 누르 십시오

다시 Git Repositories 탭에서

  • 로컬 저장소를 마우스 오른쪽 버튼으로 클릭하십시오.
  • 속성을 선택하십시오
  • 새 항목을 누릅니다 ...
  • 다음 두 키를 입력하십시오.

(1)

Key = branch.master.remote
Value = origin

(2)

Key = branch.master.merge
Value = refs/heads/master

이것은 나를 위해 일했다 :

가져올 수없는 체크 아웃 된 로컬 지점을 마우스 오른쪽 단추로 클릭합니다 ( "개발"이라고 함) "지점 구성 ..."을 선택합니다. "업스트림 지점 :"에 대해 "원격 :"에 대해 "참조 / 헤드 / 개발"을 선택했습니다. "origin"을 선택했습니다. "Rebase"를 체크하지 않았습니다

이제 내 구성 준비 창은 gview의 답변과 같습니다.


I also had problems to configure it. It is working now so I'm going to share my configuration file. I think it will help:

[core]
    repositoryformatversion = 0
    filemode = false
    logallrefupdates = true

    [branch "master"] 
        remote = origin 
        merge = refs/heads/master 
    [remote "origin"] 
        url = https://github.com/chelder86/ArcadeTongame.git
        fetch = +refs/heads/*:refs/remotes/origin/*

Note: https://github.com/chelder86/ArcadeTongame.git should be replaced with your own HTTPS clone URL.


Same problem. Here's how I solved it within eclipse/egit:

Originally I cloned a remote repo to my office computer (my own repo, but on a remote server). Then I created a new branch of repo project locally ("testing"), and pushed it to remote repository. Cloned remote repo to my laptop, switched to "testing" branch, worked on it, etc., pushed, then came back to office. When I tried to pull "testing" changes from server, got msg "local branch not configured for pull".

Problem is that on desktop, "testing" is local only, does not have remote URL info, so cannot pull changes.

I solved this within eclipse (egit) by:

  1. deleting local branch
  2. pull branch from remote repo as new branch.

Steps were:

  • Go to Git Repository Exploring perspective
  • rename local branch "zzz" (paranoid, don't like deleting until sure I've got it right!)
  • rt-click "Branches", "Switch to", "New Branch"
  • pull down "Source ref" list, select "testing" branch (pull strategy "merge", "Checkout new branch" checked)
  • click "finish"
  • Switch to usual perspective, make sure my files are present
  • switch back to Git Repository Exploring and delete branch "zzz"

Note: am running Eclipse Indigo . Steps may be different on other releases.


I just got the same issue but accepted answer did not work for me. Here's what I did (although I can't confirm if accepted answer had an impact as the updated config remains) :

Expand your git repository tree from 'Git Repositories' view.

Right click on 'Remotes' and select 'Create Remote'

Select radio button 'Configure fetch' -> 'Ok'

Select 'Change' opposite 'URI' text box

Enter your git repository details and click 'Finish'

Select 'Save'

You should now be able to pull from the remote repository.

Note - when I tried 'Dry-Run' which I think is just a connection test it failed but the pull still worked.


About gview's solution:

then find the .git directory in that working directory and edit the .git/config file with a text editor

You don't need to find it yourself or open it with a text editor.

  • Window -> Show view -> Other -> GIT -> Git Repositories
  • Expand the repo folder you created.
  • It will contain a folder called "Working Directory" expand it.
  • There will be a folder inside the "Working Directory" folder called ".git" expand it.
  • Inside ".git" there will be "config", right click "config" -> open in editor. The config file will open right in Eclipse where you can edit it. I added the following and now I can pull without errors:

[branch "master"]

remote = origin

merge = refs/heads/master


What I found that worked using eclispe (this is certainly not the right way to go about this but it works): push to remote repository, delete local workspace and repository, import from git using the import dialogue. The import wizard takes care of setting everything up for future pulls.


Try windows->Show View->Navigator. In the Navigator windows, find bin folder in your project Then commit bin folder to github and hope it work well. Try pull or fetch it after all task above.


The current branch is not configured for pull.
No value for key branch.master.merge found in configuration

An alternative for PULL (avoiding above error) is:

  1. FETCH to update your remote branch on your machine
  2. MERGE of your local branch with your remote branch
    (Team -> Merge... -> Remote Tracking -> origin/branch)

git repository view -> + branches -> local -> select the local branch you want to assign to the remote one -> right click -> select the remote (probably origin) and the upstream branch


The simplest solution I've found while using the Eclipse Git plugin is as follows:

  1. Right click the project and select Team > Push Branch
  2. Make sure the box next to "Configure upstream for push and pull" is checked
  3. Click next and complete the push.

After this completes, the branch will now be correctly configured for pull as well.


edit the config file in your repository .git folder like this.

replace https://github.com/your/uri to your github repository uri.

good luck.

[core]
    symlinks = false
    repositoryformatversion = 0
    filemode = false
    logallrefupdates = true
[branch "master"]
    remote = origin
    merge = refs/heads/master
[remote "origin"]
    url = https://github.com/your/uri
    fetch = +refs/heads/*:refs/remotes/origin/*

ps: use idea, forget eclipse


You need to replace your config file with this code.. your config file is located inside 'git' folder in your repository. The 'git' folder is hidden so first you have to show the hidden files. Open the config file and write these codes :-

[core]
repositoryformatversion = 0
filemode = false
bare = false
logallrefupdates = true
symlinks = false
ignorecase = true


hideDotFiles = dotGitOnly
[remote "origin"]
url = 'url to the git repository that you want to pull'
fetch = 

+refs/heads/*:refs/remotes/origin/*
puttykeyfile = 
[branch "master"]
remote = origin
merge = refs/heads/master
[gui]
wmstate = normal


geometry = 887x427+66+66 171 192

I got the same issue in Eclipse Neon. But none of the solution worked for me. I got the issue when I changed branch of the project and then it threw this error.The solution I tried is:

  1. Go to project/.git/config file.
  2. If rebase = false, remove it.
  3. Refresh your project.
  4. Do git pull or pull from eclipse.
  5. Error resolved.

PS: As it is an old thread, just updating as this might come in for someone else.

참고 URL : https://stackoverflow.com/questions/8820668/the-current-branch-is-not-configured-for-pull-no-value-for-key-branch-master-mer

반응형