Revision: 164
          
http://svn.sv.gnu.org/viewvc/?view=rev&root=administration&revision=164
Author:   rwp
Date:     2015-06-28 21:14:23 +0000 (Sun, 28 Jun 2015)
Log Message:
-----------
Add git fixing origin section

Modified Paths:
--------------
    trunk/sviki/UsingGit.mdwn

Modified: trunk/sviki/UsingGit.mdwn
===================================================================
--- trunk/sviki/UsingGit.mdwn   2015-06-28 21:14:13 UTC (rev 163)
+++ trunk/sviki/UsingGit.mdwn   2015-06-28 21:14:23 UTC (rev 164)
@@ -114,6 +114,23 @@
         # Send everything to Savannah
         git push
 
+Fixing checkout from git:// to ssh://
+-------------------------------------
+
+If by mistake a developer has checked out a repository using the
+public anonymous read-only git:// url this can be changed to the
+authenticated ssh:// url using git remote set-url:
+
+    git remote set-url origin ssh://[email protected]/srv/git/project.git
+
+If the origin remote has been removed, or if someone wishes to remove
+origin and recreate it, then it may be removed and set:
+
+    git remote rm origin
+    git remote add origin ssh://[email protected]/srv/git/project.git
+    git fetch
+    git branch -u origin/master master
+
 Shallow checkouts
 -----------------
 


Reply via email to