5
5

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

yosemiteにしたらgitが動かなくなった時の対処法

Last updated at Posted at 2014-10-22

以下の様なエラーが出るようになった

$ git pull
/usr/local/Cellar/git/2.1.0/libexec/git-core/git-pull: line 11: /usr/local/Cellar/git/2.1.0/libexec/git-coregit-sh-setup: No such file or directory

なんで急にnot foundになったのかはよくわからないが、とりあえず絶対パスでファイルを指定してあげるように変更することでうまく動く
以下のコマンドで一括で変更して対応した

$ cd /usr/local/Cellar/git/2.1.0/libexec/git-core
$ for f in `ls`; do sed -i -e "s/\. git-/. \$\(dirname \$0\)\/git-/g" $f; done
5
5
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
5

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?