SHARE
TWEET

Untitled

a guest Jun 13th, 2018 61 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $ git init
  2. Initialized empty Git repository in /tmp/tmp.GZDn8I0piH/.git/
  3. $ echo abc > file
  4. $ git add file
  5. $ git commit -m "Initial commit."
  6. [master (root-commit) 22fd7a1] Initial commit.
  7.  1 file changed, 1 insertion(+)
  8.  create mode 100644 file
  9. $ echo 123 >> file
  10. $ git status
  11. On branch master
  12. Changes not staged for commit:
  13.   (use "git add <file>..." to update what will be committed)
  14.   (use "git checkout -- <file>..." to discard changes in working directory)
  15.  
  16.     modified:   file
  17.  
  18. no changes added to commit (use "git add" and/or "git commit -a")
  19. $ rm .git/index
  20. $ git reset
  21. Unstaged changes after reset:
  22. M   file
  23. $ git status
  24. On branch master
  25. Changes not staged for commit:
  26.   (use "git add <file>..." to update what will be committed)
  27.   (use "git checkout -- <file>..." to discard changes in working directory)
  28.  
  29.     modified:   file
  30.  
  31. no changes added to commit (use "git add" and/or "git commit -a")
  32. $ cat file
  33. abc
  34. 123
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top