29.07.2016 Views

front-end-developer_1_

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Front-End-Developer - Level 1<br />

Git cheat sheet<br />

Basic Git workflow: Create a repository and make your first commit.<br />

Go to the top level of your project folder.<br />

cd ~/path/to/your/folder<br />

Now that you're inside your project folder, initialize a local repository.<br />

git init<br />

Configure user settings.<br />

When working with a pair, add each person individually, then add yourselves as a pair using<br />

your initials:<br />

git pair add mkn Michael Kaiser-Nyman<br />

git pair add yn Your Name<br />

git pair mkn yn<br />

When soloing:<br />

git config user.name "Your Name"<br />

git config user.email your@email.com<br />

Add all your files to the repository so that git knows to keep track of them.<br />

git add .<br />

Or add just a couple files:<br />

git add lib/kitten.rb spec/kitten_spec.rb<br />

Commit your changes.<br />

git commit -m "Add initial files."<br />

Create a remote repository on your github account. If you are pair programming, each<br />

person will have to do<br />

this separately so that the project is saved on both people's github accounts.<br />

On the github site, select the "Repositories" tab and then click the green "New" button.<br />

screenshot of button for creating a new repository<br />

Git cheat sheet<br />

91

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!