Almost technical

How about we look at how I use git? If you don’t know git I’m sure you’ll get it. Nyuck nyuck.

Find something you like on GitHub. Code that you wanna play with, that sort of thing. Hit the “fork” button to copy it over to your own GitHub account and take you directly there. Hit the clone button and copy the url. Go into your shell and cd into a folder you want to put the code you’re about to bring in. Type in git clone (then the url you just copied) and run that. Open up that code and do what you like! Make it, break it — the world is your oyster. If you want to make a branch of that code to try something out without effecting the main stuff run git checkout -b different-branch-name. This is perfect for those ideas that might ruin what you want to do so you want to test it first.

Let’s say you want to update the code you have in your repo on GitHub. You like what you’ve done and want to update your original code to reflect that. In the shell type in git add (the files you want to update, or just “.” to update everything). Typing in git commit -m “a brief message about what you changed”. This gets your code ready to replace the stuff in your repo. Then type in git push origin branch-name. This updates the stuff in your repo.

Let’s say you did something really cool and want the original author of the code to see it and possibly integrate your code into the main repo. Hit the new pull request on GitHub and then click on create pull request. This will send an invitation to the original coder to look at your code and see if they want to add it in with theirs. Hooray.

Show your support

Clapping shows how much you appreciated Stephen Landis’s story.