LoginSignup
1
1

More than 3 years have passed since last update.

【Git】gitコマンドを省略 〜エイリアス設定〜

Last updated at Posted at 2019-08-30

エイリアスとは

別名、通称...

何が出来る?

gitコマンドに別名をつけて、省略することが出来る

以下例

git checkout master
git log --oneline
git status
git commit -m 'update: ~~~~~'

git co master
git lgone
git st
git cm -m 'update: ~~~~~'

設定方法

git config --global alias.[略称] '[gitコマンド]'
git config --global alias.co 'commit'
git config --global alias.logone 'log --oneline'

  • cm : commit -m
  • co : checkout
  • logone : log --oneline
  • st : status
  • fe : fetch
  • me : merge
  • br : branch

終わりに

何か間違っていることがあればご指摘お願い致します

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