Skip to content

Instantly share code, notes, and snippets.

@yatakeke
Last active February 19, 2020 11:23
Show Gist options
  • Save yatakeke/844a8fe1ee9a290ac3b3f83f96e97816 to your computer and use it in GitHub Desktop.
Save yatakeke/844a8fe1ee9a290ac3b3f83f96e97816 to your computer and use it in GitHub Desktop.
gitの忘れやすいコマンド類を使った度に更新していく予定

git rm --cached 'file name' ファイルを管理対象から外す(-rでディレクトリごと)

git stash 一時的に変更を保存する

git stash apply stash@{num} 一時的に保存した変更を元に戻す

git checkout <file name> add前の変更を取り戻す。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment