Advertisement
Guest User

Untitled

a guest
Mar 14th, 2017
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.21 KB | None | 0 0
  1. git cheat sheet
  2.  
  3. ##
  4. ## Git setup - name and email file
  5. ##
  6.  
  7. # Set up name and email
  8. # Pair programming
  9.  
  10. # Add this file to home directory (changing name, initials and emails):
  11. .pairs
  12.  
  13. pairs:
  14. al: Ada Lovelace
  15. edlf: Enrique de la Fuente
  16. email:
  17. al: adanator@me.com
  18. edlf: queenrique@gmail.com
  19.  
  20.  
  21. #Solo setup
  22.  
  23. $ git config --global user.name "Umitosan"
  24. $ git config --global user.email yeahdom@gmail.com
  25.  
  26.  
  27. ##
  28. ## list of commands used
  29. ##
  30.  
  31. $ git init # Initializes a local REPO at current working dir - adds files inside a hidden folder called .git
  32. $ git add [filename] # adds the file and any changes made to the file to the commit
  33. $ git add . # adds ALL files recursivly that aren't already added
  34. $ git remote add [user nickname] [URL] # links local repo to remote repo
  35. $ git commit -m "commit message" # commits previously added changes AND attaches a message to the commit
  36. $ git remote -v # displays remotes - nicknames and urls
  37. $ git push [user nickname] [branch] # pushes all local commits to remote repo and specific branch (master, etc)
  38. $ git clone [remote url] # copies the remote repo to the current dir
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement