computer_science:git:resources:git_cheatsheet

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
computer_science:git:resources:git_cheatsheet [2020/11/19 16:55] carlossousacomputer_science:git:resources:git_cheatsheet [2023/12/01 12:07] (current) – external edit 127.0.0.1
Line 11: Line 11:
 git branch --set-upstream-to=origin/<branch> master git branch --set-upstream-to=origin/<branch> master
 git pull git pull
 +
 +
 +</code>
 +
 +===== Push Changes to Remote Git =====
 +
 +<code bash>
 +# Add all changes to the commit
 +git add .
 +# Commit with Comment
 +git commit -m "<comment>"
 +git push
 +
  
 </code> </code>
Line 35: Line 48:
 git push -f origin master git push -f origin master
  
 +
 +</code>
 +
 +===== Pushing new branch requires username / password =====
 +
 +<code bash>
 +# Fix with
 +git remote set-url origin git@github.com:<username>/<rep>.git
 +
 +# Push the branch
 +git push origin <branch-name>
  
 </code> </code>
  
  
  • computer_science/git/resources/git_cheatsheet.1605804959.txt.gz
  • Last modified: 2023/12/01 12:07
  • (external edit)