{"id":424,"date":"2012-08-22T09:08:53","date_gmt":"2012-08-22T09:08:53","guid":{"rendered":"http:\/\/blog.bachi.net\/?p=424"},"modified":"2020-08-26T08:46:36","modified_gmt":"2020-08-26T08:46:36","slug":"git-tutorial","status":"publish","type":"post","link":"https:\/\/blog.bachi.net\/?p=424","title":{"rendered":"Git Cheat Sheet \/ Cheatsheet"},"content":{"rendered":"<ul>\n<li>&#8220;origin&#8221; is just an alias that points to your GitHub Repository<\/li>\n<li>&#8220;upstream&#8221; is a common name for a repository that was the source of a &#8220;fork&#8221;<\/li>\n<\/ul>\n<h3>Hate git?<\/h3>\n<p><a href=\"https:\/\/stevebennett.me\/2012\/02\/24\/10-things-i-hate-about-git\/\">10 things I hate about Git<\/a><\/p>\n<h3>Tutorials<\/h3>\n<p><a href=\"https:\/\/www.ntu.edu.sg\/home\/ehchua\/programming\/howto\/Git_HowTo.html\">How to get started with GIT and work with GIT Remote Repo<\/a><br \/>\n<a href=\"http:\/\/juristr.com\/blog\/2013\/04\/git-explained\/\">Git Explained: For Beginners<\/a><br \/>\n<a href=\"http:\/\/rogerdudler.github.io\/git-guide\/index.de.html\">git &#8211; Der einfache Einstieg<\/a><br \/>\n<a href=\"http:\/\/eagain.net\/articles\/git-for-computer-scientists\/\">Git for Computer Scientists<\/a><\/p>\n<h3>Ralf Ebert<\/h3>\n<p><a href=\"https:\/\/www.ralfebert.de\/git\/historie\/\">Commit-Hashes und Historie<\/a><br \/>\n<a href=\"https:\/\/www.ralfebert.de\/git\/aenderungen-verwerfen\/\">\u00c4nderungen an Working Tree und Index verwerfen<\/a><\/p>\n<h3>Hands-On<\/h3>\n<p><a href=\"https:\/\/github.com\/dahlbyk\/git-hands-on\">Git Hands-On Workshop<\/a><br \/>\n<a href=\"https:\/\/inbo.github.io\/tutorials\/manual-git-cmd.html#\/\">Git hands-on session with command line<\/a><br \/>\n<a href=\"https:\/\/github.com\/imapex-training\/mod_adv_git\">Advanced Git and GitHub Skills<\/a><\/p>\n<h3>First Time<\/h3>\n<p><a href=\"https:\/\/readwrite.com\/2013\/09\/30\/understanding-github-a-journey-for-beginners-part-1\/\">GitHub For Beginners: Don\u2019t Get Scared, Get Started<\/a><br \/>\n<a href=\"https:\/\/gist.github.com\/blackfalcon\/8428401\">Git basics &#8211; a general workflow<\/a><\/p>\n<p><a href=\"https:\/\/www.git-tower.com\/learn\/git\/faq\/change-author-name-email\">How can I change the author name \/ email of a commit?<\/a><br \/>\n<a href=\"https:\/\/git-scm.com\/book\/en\/v2\/Getting-Started-First-Time-Git-Setup\">Getting Started &#8211; First-Time Git Setup<\/a><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git config --global core.editor &quot;'C:\/Program Files (x86)\/Notepad++\/notepad++.exe' -multiInst -nosession&quot;\r\n$ git config --list\r\n<\/pre>\n<pre class=\"brush: plain; title: Changing Your Committer Name Globally; notranslate\" title=\"Changing Your Committer Name Globally\">\r\n$ git config --global user.name &quot;Andreas Bachmann&quot;\r\n$ git config --global user.email bachi@te-clan.ch\r\n<\/pre>\n<pre class=\"brush: plain; title: hanging Your Committer Name per Repository; notranslate\" title=\"hanging Your Committer Name per Repository\">\r\n$ git config user.name &quot;Andreas Bachmann&quot;\r\n$ git config user.email bachi@te-clan.ch\r\n<\/pre>\n<h3>Staging Area (Ladedock)<\/h3>\n<p><a href=\"http:\/\/de.gitready.com\/beginner\/2009\/01\/18\/the-staging-area.html\">Der Staging Bereich<\/a><br \/>\n<a href=\"http:\/\/programmers.stackexchange.com\/questions\/119782\/what-stage-means-in-git-source-control\">What &#8216;stage&#8217; means in git source control<\/a><\/p>\n<h3>Adding empty directories<\/h3>\n<p>Short answer &#8211; you can&#8217;t.<br \/>\nThe design of the Git staging area only accounts for files, as described in the Git FAQ, and other books like Pro Git.<br \/>\n<a href=\"http:\/\/alvinalexander.com\/git\/git-empty-directories-how-add-empty-directory-repository\">Git empty directories FAQ &#8211; How to add an empty directory to Git<\/a><\/p>\n<h3>Adding a remote<\/h3>\n<p><a href=\"https:\/\/help.github.com\/articles\/adding-a-remote\">github: Adding a remote<\/a><br \/>\n<a href=\"http:\/\/caiustheory.com\/adding-a-remote-to-existing-git-repo\">Adding a remote to existing git repo<\/a><br \/>\n<a href=\"http:\/\/git-scm.com\/book\/ch2-5.html\">2.5 Git Basics &#8211; Working with Remotes<\/a><br \/>\n<a href=\"http:\/\/git-scm.com\/book\/en\/v2\/Git-Basics-Working-with-Remotes\">Git Basics &#8211; Working with Remotes<\/a><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git remote -v\r\norigin\t\/home\/andreas\/src\/ZZZ (fetch)\r\norigin\t\/home\/andreas\/src\/ZZZ (push)\r\n\r\n$ git remote remove origin\r\n$ git remote -v\r\n$ git remote add origin https:\/\/XXX.ch\/svn\/ZZZ\/trunk\r\n$ git remote -v\r\norigin\thttps:\/\/XXX.ch\/svn\/ZZZ\/trunk (fetch)\r\norigin\thttps:\/\/XXX.ch\/svn\/ZZ\/trunk (push)\r\n\r\n$ git svn fetch --fetch-all\r\n<\/pre>\n<h3>Branching and Merging<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git branch -a\r\nLokal (gr\u00fcn)\r\n* master\r\nExtern (rot)\r\n  remotes\/origin\/HEAD -&gt; origin\/master\r\n  remotes\/origin\/feature\/psram_malloc\r\n  remotes\/origin\/master\r\n  remotes\/origin\/release\/v2.0\r\n  remotes\/origin\/release\/v2.1\r\n\r\n$ git remote -v\r\norigin\thttps:\/\/github.com\/espressif\/esp-idf.git (fetch)\r\norigin\thttps:\/\/github.com\/espressif\/esp-idf.git (push)\r\n<\/pre>\n<ul>\n<li><code>master<\/code> Branch (Zeiger)<\/li>\n<li><code>origin<\/code> Repository<\/li>\n<li><code>HEAD<\/code> der &#8220;aktuelle Branch&#8221;<\/li>\n<\/ul>\n<h4>Externe Branches<\/h4>\n<p>Externe (Remote) Branches sind <strong>Referenzen<\/strong> auf den Zustand der Branches in Deinen externen Repositorys. Es sind lokale Branches die Du nicht ver\u00e4ndern kannst, sie werden automatisch ver\u00e4ndert wann immer Du eine Netzwerkoperation durchf\u00fchrst. <strong>Externe Branches<\/strong> verhalten sich wie <strong>Lesezeichen<\/strong>, um Dich daran zu erinnern an welcher Position sich die Branches in Deinen externen Repositories befanden, als Du Dich zuletzt mit ihnen verbunden hattest.<\/p>\n<h4>Hochladen<\/h4>\n<p>Deine lokalen Zweige (Branches) werden nicht automatisch mit den Remote-Servern synchronisiert wenn Du etwas \u00e4nderst \u2013 Du musst die zu ver\u00f6ffentlichenden Branches explizit hochladen (pushen).<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n  git push (remote) (branch)\r\n$ git push origin serverfix\r\n<\/pre>\n<p>Hierbei handelt es sich um eine Abk\u00fcrzung. Git erweitert die <code>serverfix<\/code>-Branchbezeichnung automatisch zu <code>refs\/heads\/serverfix:refs\/heads\/serverfix<\/code>, was soviel bedeutet wie \u201cNimm meinen lokalen serverfix-Branch und aktualisiere damit den serverfix-Branch auf meinem externen Server\u201d<br \/>\nDu kannst auch <code>git push origin serverfix:serverfix<\/code> ausf\u00fchren, was das gleiche bewirkt \u2013 es bedeutet \u201cNimm meinen serverfix und mach ihn zum externen serverfix\u201d<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git fetch origin\r\n<\/pre>\n<p>Es ist wichtig festzuhalten, dass Du mit Abrufen eines neuen externen Branches nicht automatisch eine lokale, bearbeitbare Kopie derselben erh\u00e4ltst. Mit anderen Worten, in diesem Fall bekommst Du keinen neuen <code>serverfix<\/code>-Branch \u2013 sondern nur einen <code>origin\/serverfix<\/code>-Zeiger den Du nicht ver\u00e4ndern kannst.<\/p>\n<p>Wenn Du Deine eigene Arbeitskopie des serverfix-Branches erstellen m\u00f6chtest, dann kannst Du diesen auf Grundlage des externen Zweiges erstellen:<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git checkout -b serverfix origin\/serverfix\r\nBranch serverfix set up to track remote branch refs\/remotes\/origin\/serverfix.\r\nSwitched to a new branch &quot;serverfix&quot;\r\n<\/pre>\n<p>Dies erstellt Dir einen lokalen bearbeitbaren Branch mit der Grundlage des <code>origin\/serverfix<\/code>-Zweiges.<\/p>\n<h4>Tracking Branches<\/h4>\n<p>Das Auschecken eines lokalen Branches von einem Remote-Branch erzeugt automatisch einen sogenannten Tracking-Branch. Tracking Branches sind lokale Branches mit einer direkten Beziehung zu dem Remote-Zweig. Wenn Du Dich in einem Tracking-Branch befindest und git push eingibst, wei\u00df Git automatisch zu welchem Server und Repository es pushen soll. Ebenso f\u00fchrt git pull in einem dieser Branches dazu, dass alle entfernten Referenzen gefetched und automatisch in den Zweig gemerged werden.<\/p>\n<p><a href=\"https:\/\/git-scm.com\/book\/de\/v1\/Git-Branching-Externe-Branches\">Git Branching &#8211; Externe Branches<\/a><br \/>\n<a href=\"http:\/\/aruizca.com\/git-houseleeping-remove-redundant-branches-from-the-remote-and-your-local-repositories\/\">Git housekeeping: remove &#8220;redundant&#8221; branches from the remote and your local repositories<\/a><\/p>\n<p><a href=\"http:\/\/nvie.com\/posts\/a-successful-git-branching-model\/\">A successful Git branching model<\/a><br \/>\n<a href=\"https:\/\/www.atlassian.com\/git\/tutorials\/comparing-workflows\/gitflow-workflow\">Gitflow Workflow<\/a><br \/>\n<a href=\"http:\/\/blog.endpoint.com\/2014\/05\/git-workflows-that-work.html\">Git Workflows That Work<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/2621610\/what-git-branching-models-work-for-you\">What Git branching models work for you?<\/a><\/p>\n<p><a href=\"http:\/\/git-scm.com\/book\/en\/Git-Branching-Basic-Branching-and-Merging\">3.2 Git Branching &#8211; Basic Branching and Merging<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/2304087\/what-is-git-head-exactly\">What is git HEAD, exactly?<\/a><\/p>\n<p><a href=\"http:\/\/git-scm.com\/book\/en\/v2\/Git-Branching-Remote-Branches\">3.5 Git Branching &#8211; Remote Branches<\/a><\/p>\n<h3>Tilde, Hat, At<\/h3>\n<ul>\n<li><code>HEAD~2<\/code><\/li>\n<li><code>HEAD^2<\/code><\/li>\n<li><code>HEAD@{2}<\/code><\/li>\n<li><code>HEAD~~<\/code><\/li>\n<li><code>HEAD^^<\/code><\/li>\n<\/ul>\n<p><a href=\"http:\/\/stackoverflow.com\/questions\/26785118\/head-vs-head-vs-head-also-known-as-tilde-vs-caret-vs-at-sign\/26785200\">HEAD~ vs HEAD^ vs HEAD@{} also known as tilde vs caret vs at sign<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/2221658\/whats-the-difference-between-head-and-head-in-git\">What&#8217;s the difference between HEAD^ and HEAD~ in Git?<\/a><br \/>\n<a href=\"http:\/\/schacon.github.io\/git\/git-rev-parse#_specifying_revisions\">git-rev-parse &#8211; Pick out and massage parameters<\/a><\/p>\n<h3>Undo<\/h3>\n<p><a href=\"https:\/\/www.atlassian.com\/git\/tutorials\/undoing-changes\">Undoing Changes<\/a><\/p>\n<pre class=\"brush: plain; title: Revert localy modified changes (working copy); notranslate\" title=\"Revert localy modified changes (working copy)\">\r\n$ git checkout &lt;file&gt;\r\nor\r\n$ git reset --hard\r\n<\/pre>\n<h4>Remove latest commit<\/h4>\n<pre class=\"brush: plain; title: Keeping local modifications; notranslate\" title=\"Keeping local modifications\">\r\n$ git reset --soft HEAD~1\r\n<\/pre>\n<h4>Mistakenly reset<\/h4>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git reset HEAD^4\r\n\r\n$ git log --oneline\r\nc5cada1 (HEAD -&gt; master) move code to object-oriented design\r\ncbac193 add splash screen\r\n12a215f add FotoFinder logo\r\n3ddcbea initial commit\r\n\r\n$ git reflog\r\nc5cada1 (HEAD -&gt; master) HEAD@{0}: reset: moving to HEAD^\r\nc67578c HEAD@{1}: reset: moving to HEAD^\r\n6fac355 (origin\/master, origin\/HEAD) HEAD@{2}: reset: moving to HEAD~\r\n952985d HEAD@{3}: reset: moving to HEAD~\r\ne2c44d1 HEAD@{4}: revert: Revert &quot;Communication module: receive with timeout&quot;\r\n952985d HEAD@{5}: commit: Communication module: receive with timeout\r\n6fac355 (origin\/master, origin\/HEAD) HEAD@{6}: commit: splashscreen state-machine\r\nc67578c HEAD@{7}: commit: refactor code design\r\nc5cada1 (HEAD -&gt; master) HEAD@{8}: commit: move code to object-oriented design\r\ncbac193 HEAD@{9}: commit: add splash screen\r\n12a215f HEAD@{10}: commit: add FotoFinder logo\r\n3ddcbea HEAD@{11}: reset: moving to HEAD\r\n3ddcbea HEAD@{12}: clone: from https:\/\/github.zhaw.ch\/dermolockin\/DermaIrEsp32Display.git\r\n\r\n$ git checkout --force 952985d .\r\n\r\nCommit without log?!\r\n<\/pre>\n<h3>Pushing amended commits<\/h3>\n<p><a href=\"http:\/\/stackoverflow.com\/questions\/11184267\/how-to-push-to-repo-after-doing-git-commit-amend\">How to push to repo after doing &#8216;git commit &#8211;amend&#8217;<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/3968281\/git-pushing-amended-commits\">Git: pushing amended commits<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/253055\/how-do-i-push-amended-commit-to-the-remote-git-repo\">How do I push amended commit to the remote git repo?<\/a><\/p>\n<pre class=\"brush: plain; title: Problem; notranslate\" title=\"Problem\">\r\n$ git commit &#x5B;...]\r\n$ git push\r\n\r\n$ git commit --amend --reset-author\r\nor\r\n$ git commit --amend --author=&quot;Andreas Bachmann &lt;bachi@te-clan.ch&quot;\r\n\r\n$ git push\r\nTo git@github.com:user\/repo.git\r\n ! &#x5B;rejected]        master -&gt; master (non-fast-forward)\r\nerror: failed to push some refs to 'git@github.com:user\/repo.git'\r\n<\/pre>\n<p>No other commits are pushed:<\/p>\n<pre class=\"brush: plain; title: Solution; notranslate\" title=\"Solution\">\r\n$ git push --force\r\nCounting objects: 1, done.\r\nWriting objects: 100% (1\/1), 207 bytes | 0 bytes\/s, done.\r\nTotal 1 (delta 0), reused 0 (delta 0)\r\nTo git@github.com:te-bachi\/dns-amplification-defender.git\r\n + 4f3ec7c...de70182 master -&gt; master (forced update)\r\n<\/pre>\n<h3>Commit only modified<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git add -u\r\nor\r\n$ git commit -a\r\n<\/pre>\n<p><a href=\"http:\/\/stackoverflow.com\/questions\/7124726\/git-add-only-modified-changes-and-ignore-untracked-files\">git add only modified changes and ignore untracked files<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/572549\/difference-between-git-add-a-and-git-add\/572660#572660\">Difference between \u201cgit add -A\u201d and \u201cgit add .\u201d<\/a><\/p>\n<h3>Color<\/h3>\n<p><a href=\"http:\/\/michael.otacoo.com\/linux-2\/avoid-escape-characters-in-git\/\">Avoid escape characters in GIT<\/a><br \/>\n<a href=\"http:\/\/unix.stackexchange.com\/questions\/19317\/can-less-retain-colored-output\">Can less retain colored output?<\/a><br \/>\n<a href=\"http:\/\/unix.stackexchange.com\/questions\/64927\/git-diff-displays-colors-incorrectly\">git diff displays colors incorrectly<\/a><\/p>\n<pre class=\"brush: plain; title: Problem; notranslate\" title=\"Problem\">\r\nESC&#x5B;1mdiff --git a\/include\/packet\/ethernet_header.h b\/include\/packet\/ethernet_header.hESC&#x5B;m\r\nESC&#x5B;1mindex 9239f0b..a8f6553 100644ESC&#x5B;m\r\nESC&#x5B;1m--- a\/include\/packet\/ethernet_header.hESC&#x5B;m\r\nESC&#x5B;1m+++ b\/include\/packet\/ethernet_header.hESC&#x5B;m\r\nESC&#x5B;36m@@ -53,6 +53,7 @@ESC&#x5B;m ESC&#x5B;mstruct _ethernet_header_t {ESC&#x5B;m\r\n<\/pre>\n<pre class=\"brush: plain; title: Solution; notranslate\" title=\"Solution\">\r\n$ git config --global core.pager &quot;more -r&quot;\r\n<\/pre>\n<h3>Von Revision zu Revision springen<\/h3>\n<p><a href=\"http:\/\/stackoverflow.com\/questions\/34519665\/how-to-move-head-back-to-a-previous-location-detached-head\/34519716\">How to move HEAD back to a previous location? (Detached head)<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/6759791\/how-do-i-move-forward-and-backward-between-commits-in-git\">How do I move forward and backward between commits in git?<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/4114095\/how-to-revert-git-repository-to-a-previous-commit\">How to revert Git repository to a previous commit?<\/a><\/p>\n<pre class=\"brush: plain; title: HEAD bleibt bestehen; notranslate\" title=\"HEAD bleibt bestehen\">\r\n$ git checkout HEAD~1 .\r\n<\/pre>\n<pre class=\"brush: plain; title: HEAD \u00e4ndert sich =&gt; detached branch; notranslate\" title=\"HEAD \u00e4ndert sich =&gt; detached branch\">\r\n$ git checkout HEAD~1\r\n==&gt; HEAD ist nun eins zur\u00fcck\r\n\r\n$ git checkout master\r\n==&gt; HEAD wieder auf master\r\n<\/pre>\n<h3>Log \/ Diff<\/h3>\n<p><a href=\"https:\/\/stackoverflow.com\/questions\/5694389\/get-the-short-git-version-hash\">Get the short git version hash<\/a><\/p>\n<p>abbreviated SHA-1 checksum<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git log --abbrev-commit doc\/Bericht_BA18_DermoInspectMini\/BerichtBA.tex\r\ncommit 52570bc\r\nAuthor: Giaele Quadri &lt;quadrgia@students.zhaw.ch&gt;\r\nDate:   Mon Feb 26 20:52:27 2018 +0100\r\n&#x5B;...]\r\n<\/pre>\n<p>full checksum<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git log doc\/Bericht_BA18_DermoInspectMini\/BerichtBA.tex\r\ncommit 52570bc4ee5f67de56143fa616369ed812613a6d\r\nAuthor: Giaele Quadri &lt;quadrgia@students.zhaw.ch&gt;\r\nDate:   Mon Feb 26 20:52:27 2018 +0100\r\n&#x5B;...]\r\n<\/pre>\n<p>diff<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git diff 52570bc ea5102a doc\/Bericht_BA18_DermoInspectMini\/BerichtBA.tex\r\ndiff --git a\/doc\/Bericht_BA18_DermoInspectMini\/BerichtBA.tex b\/doc\/Bericht_BA18_DermoInspectMini\/BerichtBA.tex\r\nindex e6742cb..dc5a2b9 100644\r\n--- a\/doc\/Bericht_BA18_DermoInspectMini\/BerichtBA.tex\r\n+++ b\/doc\/Bericht_BA18_DermoInspectMini\/BerichtBA.tex\r\n&#x5B;...]\r\n<\/pre>\n<h3>Revision Log<\/h3>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git reflog\r\nc9daee7 HEAD@{0}: checkout: moving from fdfcceea0650e3a96e83175eb53d59360f63a779 to HEAD@{1}\r\nfdfccee HEAD@{1}: checkout: moving from c9daee7cd6036fab5826ddb3f19c3c7669dca041 to HEAD@{1}\r\nc9daee7 HEAD@{2}: checkout: moving from fdfcceea0650e3a96e83175eb53d59360f63a779 to HEAD@{1}\r\nfdfccee HEAD@{3}: checkout: moving from c9daee7cd6036fab5826ddb3f19c3c7669dca041 to HEAD@{1}\r\nc9daee7 HEAD@{4}: checkout: moving from fdfcceea0650e3a96e83175eb53d59360f63a779 to HEAD@{1}\r\nfdfccee HEAD@{5}: checkout: moving from c9daee7cd6036fab5826ddb3f19c3c7669dca041 to HEAD~1\r\nc9daee7 HEAD@{6}: checkout: moving from 724fe825b81cbfc26448ae38276ab72aff5848b4 to HEAD~1\r\n724fe82 HEAD@{7}: checkout: moving from master to HEAD~1\r\n80a7302 HEAD@{8}: commit: Move logic to PhysioTrain.cpp\r\n724fe82 HEAD@{9}: checkout: moving from c9daee7cd6036fab5826ddb3f19c3c7669dca041 to master\r\nc9daee7 HEAD@{10}: checkout: moving from master to HEAD~1\r\n724fe82 HEAD@{11}: commit: Move logic to PhysioTrain.cpp\r\nc9daee7 HEAD@{12}: commit: PES4: communication between the two IMUs and the MCU\r\nfdfccee HEAD@{13}: commit: Add header comment\r\naef832e HEAD@{14}: commit: Log out acceleration and quaternion\r\n2ccaf0c HEAD@{15}: commit: Initial PhysioTrain\r\n62bc3fa HEAD@{16}: clone: from git@github.com:te-bachi\/PhysioTrain.git\r\n<\/pre>\n<h3>Glossary<\/h3>\n<table>\n<tr>\n<td>master<\/td>\n<td>&#8220;Standard&#8221;-Branch<\/td>\n<tr>\n<td>origin<\/td>\n<td>&#8220;Standard&#8221;-Remote Repository<\/td>\n<tr>\n<td>index<\/td>\n<td>Gleich wie staging area<\/td>\n<tr>\n<td>stage \/ staging area<\/td>\n<td>Ladedock, wo du entscheidest welche \u00c4nderungen verschifft (commited) werden.<\/td>\n<tr>\n<td>HEAD<\/td>\n<td>Der aktuell benutzte Branch<\/td>\n<\/table>\n<h3>Subversion<\/h3>\n<p>Siehe auch <a href=\"http:\/\/blog.bachi.net\/?p=543\">Subversion<\/a> -> Migration<\/p>\n<p><a href=\"http:\/\/git-scm.com\/book\/de\/v1\/Git-und-andere-Versionsverwaltungen-Git-und-Subversion\">8.1 Git und andere Versionsverwaltungen &#8211; Git und Subversion<\/a><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git svn clone https:\/\/server\/project project\r\n$ cd project\r\n$ git commit -m &quot;...&quot;\r\n$ git svn dcommit\r\n<\/pre>\n<p><a href=\"http:\/\/www.robbyonrails.com\/articles\/2008\/04\/10\/git-svn-is-a-gateway-drug\">Robby on Rails &#8211; git-svn is a gateway drug &#8211; Working with Subversion branches<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/192736\/how-do-i-make-git-svn-use-a-particular-svn-branch-as-the-remote-repository\">How do I make git-svn use a particular svn branch as the remote repository?<\/a><br \/>\n<a href=\"http:\/\/stackoverflow.com\/questions\/728931\/how-to-switch-svn-branches-using-git-svn\">How to switch svn branches using git-svn?<\/a><\/p>\n<h4>Subversion Remote Branch<\/h4>\n<p><a href=\"http:\/\/stackoverflow.com\/questions\/296975\/how-do-i-tell-git-svn-about-a-remote-branch-created-after-i-fetched-the-repo\">How do I tell git-svn about a remote branch created after I fetched the repo?<\/a><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git config --add svn-remote.newbranch.url https:\/\/svn\/path_to_newbranch\/\r\n$ git config --add svn-remote.newbranch.fetch :refs\/remotes\/newbranch\r\n$ git svn fetch newbranch &#x5B;-r&lt;rev&gt;]\r\n$ git checkout -b local-newbranch -t newbranch\r\n$ git svn rebase newbranch\r\n<\/pre>\n<h3>I don&#8217;t handle protocol &#8216;https&#8217;<\/h3>\n<p><a href=\"http:\/\/stackoverflow.com\/questions\/30474447\/git-fatal-i-dont-handle-protocol-http\">git: fatal: I don&#8217;t handle protocol &#8216;\u200b\u200bhttp&#8217;<\/a><\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git clone https:\/\/github.com\/xxx\/repo.git\r\nCloning into 'repo'...\r\nfatal: I don't handle protocol 'https'\r\n\r\n$ git --version\r\ngit version 2.4.5\r\n<\/pre>\n<blockquote><p>I copied and pasted the whole line git clone &#8230;.<br \/>\nThe character between clone and http:\/\/&#8230; looks like a space, but it is a special Unicode character!<br \/>\nAfter removing this empty character, and entering a real space, it worked!<\/p><\/blockquote>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\n$ git clone https:\/\/github.com\/xxx\/repo.git\r\nCloning into 'repo'...\r\nremote: Counting objects: 146, done.\r\nReceiving objects:  87remote: Total 146 (delta 0), reused 0 (delta 0), pack-reused 146\r\nReceiving objects: 100% (146\/146), 74.51 KiB | 0 bytes\/s, done.\r\nResolving deltas: 100% (76\/76), done.\r\nChecking connectivity... done.\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>&#8220;origin&#8221; is just an alias that points to your GitHub Repository &#8220;upstream&#8221; is a common name for a repository that was the source of a &#8220;fork&#8221; Hate git? 10 things I hate about Git Tutorials How to get started with GIT and work with GIT Remote Repo Git Explained: For Beginners git &#8211; Der einfache [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[10],"tags":[],"class_list":["post-424","post","type-post","status-publish","format-standard","hentry","category-ubuntu"],"_links":{"self":[{"href":"https:\/\/blog.bachi.net\/index.php?rest_route=\/wp\/v2\/posts\/424","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.bachi.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.bachi.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.bachi.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.bachi.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=424"}],"version-history":[{"count":49,"href":"https:\/\/blog.bachi.net\/index.php?rest_route=\/wp\/v2\/posts\/424\/revisions"}],"predecessor-version":[{"id":11309,"href":"https:\/\/blog.bachi.net\/index.php?rest_route=\/wp\/v2\/posts\/424\/revisions\/11309"}],"wp:attachment":[{"href":"https:\/\/blog.bachi.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=424"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.bachi.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=424"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.bachi.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=424"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}