Skip to content

Instantly share code, notes, and snippets.

@davidkhala
Last active February 26, 2021 05:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davidkhala/014d02a82cc9bf25bbcc48f58ca0239b to your computer and use it in GitHub Desktop.
Save davidkhala/014d02a82cc9bf25bbcc48f58ca0239b to your computer and use it in GitHub Desktop.
Git cheat sheet
  • Git in windows using CRLF for line-break and spaces
  • Git in Unix version it use CL, which will leads to lots of syntax error when running script

Apply git patch

git am <patch-file-path>

Resolve conflict if any

git am -3

list modified files (including staged, excluding untracked)

!git status -s | cut -c1-3 --complement

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