티스토리 뷰

개발

agnoster.zsh-theme:91: parse error near `<<<

달리는개발자 2021. 5. 28. 09:19

윈도우 WSL에서 아래 로그와 같이 오류가 난다

/home/aaa/.oh-my-zsh/themes/agnoster.zsh-theme:91: parse error near `<<<

error: Pulling is not possible because you have unmerged files.
hint: Fix them up in the work tree, and then use 'git add/rm <file>'
hint: as appropriate to mark resolution and make a commit.
fatal: Exiting because of an unresolved conflict.
There was an error updating. Try again later?
/home/aaa/.oh-my-zsh/themes/agnoster.zsh-theme:91: parse error near `<<<'
aaa-WIN%
aaa-WIN% git status
fatal: not a git repository (or any parent up to mount point /mnt)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).

 

해당 파일을 보니 아래와 같이 git conflict가 났다.

 89 # Context: user@hostname (who am I and where am I)
 90 prompt_context() {
 91 <<<<<<< Updated upstream
 92   if [[ "$USERNAME" != "$DEFAULT_USER" || -n "$SSH_CLIENT" ]]; then
 93     prompt_segment black default "%(!.%{%F{yellow}%}.)%n@%m"
 94 =======
 95   if [[ "$USER" != "$DEFAULT_USER" || -n "$SSH_CLIENT" ]]; then
 96     prompt_segment green black "%(!.%{%F{yellow}%}.)%n@%m"
 97 >>>>>>> Stashed changes

 

링크를 참고해서 수정했다.

cd $ZSH
git config core.autocrlf input
git rm --cached -r .
git reset --hard

https://github.com/agnoster/agnoster-zsh-theme/issues/155

반응형
댓글
반응형
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
«   2025/01   »
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
글 보관함