If git push keeps asking you for user/pass, chances are that you did a git clone using HTTPS. Fix that by going to your repo page on github, then click on the SSH link below the clone URL field, then copy that URL over (something like email@example.com_username/your_repo_name.git). Then update your local git repo with something like the following command
If any of you out there are trying to learn Git, here is a free book online called Pro Git. It’s pretty clear and easy to understand.
What is Git?
Git is a free & open source, distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
Every Git clone is a full-fledged repository with complete history and full revision tracking capabilities, not dependent on network access or a central server. Branching and merging are fast and easy to do.
Perhaps Git is still new, I couldn’t find any one-click solutions to simply pulling a copy from a git repository in osx. If you are new to git, and you are a osx user, and you just want to pull the latest code from a repository, you are at the right place. I will show you the quickest way to do just that.
1. First download git-osx-installer at http://code.google.com/p/git-osx-installer/
2. Install it (you will need root login). After that, you should have /usr/bin/git
3. Say you want to pull from git://github.com/omz/AppSales-Mobile.git
4. Make a directory, for example: mkdir myApp
5. cd myApp
6. At this point, you would want to do a “git clone git://github.com/omz/AppSales-Mobile.git”. However, I bet you will get some error messages. So read on. 😉
7. Type “locate git-core”, check to see that you have “/usr/local/git/share/git-core/templates/”.
8. Type “locate index-pack”, check to see that you have “/usr/local/git/libexec/git-core/git-index-pack”
9. Now, set the path: export PATH=/usr/local/git/libexec/git-core/:$PATH (or wherever git-index-pack is located at from step #8)
10. Issue this command: git clone --template=/usr/local/git/share/git-core/templates/ git://github.com/omz/AppSales-Mobile.git
This should probably save you some time googling around…
If you are doing more than just pulling code, you should probably add the path info into your bashrc file or so.