From 90fcb4ac6110475b0470f1053b56dbe1698a2816 Mon Sep 17 00:00:00 2001 From: Mhrooz Date: Fri, 16 Aug 2024 10:39:20 +0200 Subject: [PATCH] add 2.5 notes --- notes/2.5_git_checkout.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 notes/2.5_git_checkout.md diff --git a/notes/2.5_git_checkout.md b/notes/2.5_git_checkout.md new file mode 100644 index 0000000..6962dc9 --- /dev/null +++ b/notes/2.5_git_checkout.md @@ -0,0 +1,16 @@ +## 2.5 Git Checkout + +### 2.5.1 HEAD reset = checkout + +查看当前的branch +```bash +git branch -v +``` + +checkout到commit的父亲,使得head指针指向父提交,而不是branch +```bash +git checkout ^ +``` + + +