Re: How to host a github?
From: daicoden <hidden>
Date: 2016-06-15 22:47:26
jvsrvcs wrote:
I want to share code with a few co-workers and I want to use git. I installed git (cygwin), created a /project/ and then $cd project and then $git init I have found so much documentation as to what to do next, that I'm confused. Do I have to create an account on github in order to share code with a few local developers? Could I run some sort of server on my laptop in order to share code? (we only need to share during office hours). Basically I just want to share code but do not want to sign up for an account on github. How do I work this? thanks jvsrvcs
Hey, assuming you have shell access into your laptop, create a user named git. You don't have to do this but you want to give everyone access to an account on the laptop. You could also create a usergroup and add the project folder to that group and give all your developers access to that group. Either-way once everyone is able to log onto the laptop make a new directory called project.git. Then go into that directory and use git --bare init. Assuming you created a user named git you can then check the code out via git clone git@localhost:project.git to start things off from the source you will be working on you can then use: git init touch 'Readme' git add Readme git commit -m 'Initial Comit' git remote add origin git@ip:project.git git push origin master -- View this message in context: http://www.nabble.com/How-to-host-a-github--tp24713161p25525401.html Sent from the git mailing list archive at Nabble.com.