LoginSignup
2
1

More than 1 year has passed since last update.

【Git】git configの設定

Last updated at Posted at 2023-02-07

はじめに

Railsなどを中心に勉強中のエンジニア初心者が他の記事を参考にしたり、実際に実装してみたりして、アウトプットの一環としてまとめたものです。
間違っていることもあると思われるので、その際は指摘いただけると幸いです。

git configの設定

gitの初期設定としてユーザー名と、メールアドレスを登録する必要がある。

この設定情報がcommitmergeした際に誰が実行したかログとして残る。

実行コマンド

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

# gitの設定を確認
git config --list

実行結果

% git config --global user.name "user_name"
% git config --global user.email "user_name@email.com"

% git config --list
credential.helper=osxkeychain
init.defaultbranch=main
user.name=user_name
user.email=user_name@email.com

参考

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