티스토리 뷰

반응형

터미널을 열 때마다 다음과 같은 복잡한 메시지가 출력되곤 했습니다. 

 

[oh-my-zsh] Insecure completion-dependent directories detected:
drwxrwxr-x  3 jypark  admin   96  3 23 23:00 /usr/local/share/zsh
drwxrwxr-x  4 jypark  admin  128  3 23 23:16 /usr/local/share/zsh/site-functions

[oh-my-zsh] For safety, we will not load completions from these directories until
[oh-my-zsh] you fix their permissions and ownership and restart zsh.
[oh-my-zsh] See the above list for directories with group or other writability.

[oh-my-zsh] To fix your permissions you can do so by disabling
[oh-my-zsh] the write permission of "group" and "others" and making sure that the
[oh-my-zsh] owner of these directories is either root or your current user.
[oh-my-zsh] The following command may help:
[oh-my-zsh]     compaudit | xargs chmod g-w,o-w

[oh-my-zsh] If the above didn't help or you want to skip the verification of
[oh-my-zsh] insecure directories you can set the variable ZSH_DISABLE_COMPFIX to
[oh-my-zsh] "true" before oh-my-zsh is sourced in your zshrc file.

 

위와 같은 증상을 찾아보니 해당 디렉터리의 owner와 현재 user가 달라 충돌이 발생하는 경우에 발생하는 증상이라고 합니다.

이러한 경우 아래와 같이 수정하였습니다. 

 

> vi ~/.zshrc

71 plugins=(git)
72
73 ZSH_DISABLE_COMPFIX="true"
74
75 source $ZSH/oh-my-zsh.sh

위의 줄을 .zshrc 에 추가해주면 증상이 사라집니다. 

반응형
댓글
공지사항