LoginSignup
0
0

More than 5 years have passed since last update.

たまに活用するGitコマンド一覧

Last updated at Posted at 2017-02-10

たまに活用するGitコマンド一覧

remote branchの一覧を表示する

$ git ls-remote

追跡branchの変更をする

$ git branch origin/○○

新しくGitLabで作成したbranchをpullする。

$ git pull origin ○○

既存のプロジェクトをGit管理にする

$ git init
$ git remote add origin ○○○○○○○○○○○○○○○○○○○○.git

リモートブランチが表示されない際に

$ git fetch -all

Gitの作業ログを確認する。

$ git reflog

最新のコミットを取り消す

$ git reset --hard HEAD^
0
0
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
0
0