Git commands for pair programming
At my work I'm on an agile team and we do pair programming. Here are some git commands I find useful and use almost every day.
At my work I'm on an agile team and we do pair programming. Here are some git commands I find useful and use almost every day.
Every day I see new Linux Kernel hackers fail at their first patch submission. I'm not an expert, but I've learned how the process works and most importantly I've learned how to avoid irritating Linux Kernel maintainers. The "maintainers" are the gate keepers to the Linux Kernel. If you piss them off you will never land any patches into the Linux Kernel. All Linux Kernel development takes place in the open and hundreds (thousands?) of Linux Kernel developers will see and possibly read your patch submissions. You will want to make every effort to submit the best possible patch you can. That's where I come in. If you follow my guide there's a better than average chance you will actually land your patch into the Linux Kernel. For a beginner I recommend working on the drivers/staging tree maintained by Greg Kroah-Hartman. Clone Greg KH's staging tree: > git clone git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git This will take a while. After that you need to checkou
If you want to leave Github for whatever reason, you probably want to take all your code with you, and all your history and branches, etc. Here's an example for how I moved my Android Eclipse workspace from Github to my own remote server. First I make a new git repo on my remote server: $ git --bare init ~/git/workspace The --bare option means I'm not going to work on the code in the remote git repo directly. Next I push my current local 'master' to the new repo: $ git checkout master $ git push ssh://me@myserver.com/git/workspace master After that I push my working branch: $ git checkout work $ git push ssh://me@myserver.com/git/workspace work You could repeat this step if you have more branches. I created my local repo using 'clone' so it has an 'origin' remote branch defined. This 'remote' branch is where git fetches and pushes changes. Right now my 'fetch' and 'push' remote origins point to Github: $ git remote -v git@github.com:gdonald/workspace.git