create notes file on git

This commit is contained in:
Akbar Rahman 2021-07-27 21:07:51 +01:00
parent 58c7334d86
commit 5deb7a4d0e

25
git.md Executable file
View File

@ -0,0 +1,25 @@
---
author: Alvie Rahman
date: \today
title: Git notes
---
# Fix detached head
From https://stackoverflow.com/a/10229202 :
## To Delete Changes
```
git checkout main
```
## To Keep Changes
```
git branch temp
git checkout main
git pull . temp
git branch -D temp
```