- Posted by dan on March 12, 2012
Quick note, I've been playing with Git repository's of late just simply storing the repo on an internally shared drive. It's so much simpler than setting up a http server to do the job.
While no GitHub replacement for little internal tools it's fine.
- Goto your shared drive in bash cd /s/repos if your shared drive is S drive
- mkdir MyAmazingProject.git
- cd MyAmazingProject.git
- git init --bare
That's it really, then on you local machine(s) Assuming you've got the initial code to push to your new shiny repository
- cd /c/MyAmazingProject (assumes your project is on the c:\myamazingproject
- git init
- git add .
- git commit -m "initial commit"
- git remote add origin /s/repos/MyAmazingProject.git
- git push origin master
This will push an initial version of the code to your bare repository.
Then you can send round the url for team members to clone the git repository.
- git clone /s/repos/MyAmazingProject.git
- cd /c/MyAmazingProject
Your done, everyone can now work and push up to the repository on S which is hopefully backed up more often than your local machine.