LoginSignup
5
2

More than 5 years have passed since last update.

Gitでよく使う設定

Last updated at Posted at 2015-02-01
git-config

git config --global user.name "ユーザ名"
git config --global user.email "メールアドレス"

# git diff で日本語を表示する
git config --global core.pager "LESSCHARSET=utf-8 less"

# gitのcommitメッセージにvimを利用する
git config --global core.editor 'vim -c "set fenc=utf-8"'

# gitでの認証情報を保存する
git config --global credential.helper store

# gitのpushでブランチ名省略時に安全に処理する(現在のブランチで同名の場合)
git config --global push.default simple

# デフォルトのignore設定
git config --global core.excludesfile $HOME/.gitignore_global

# 自動で改行コードの変更をしない
git config --global core.autoCRLF false

# globalなgitignoreを設定
git config --global core.excludesfile ~/.gitignore_global

5
2
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
2