You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: version-control/command-line/tutorial.md
+5-1Lines changed: 5 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -500,5 +500,9 @@ After typing a couple of commands in the terminal to generate some history, try
500
500
501
501
> You can see the entire history by running `history`
502
502
503
-
---
503
+
## The next step
504
+
505
+
Get learning JavaScript, HTML, CSS, Ruby and more on [Codebar](http://tutorials.codebar.io/).
506
+
507
+
-----
504
508
This ends **Introduction to the Git command line** tutorial. Is there something you don't understand? Try and go through the provided resources with your coach. If you have any feedback, or can think of ways to improve this tutorial [send us an email](mailto:[email protected]) and let us know.
Copy file name to clipboardExpand all lines: version-control/introduction/tutorial.md
+3-54Lines changed: 3 additions & 54 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -97,9 +97,9 @@ As with any technology and related tool, there's a lot of terminology realted to
97
97
98
98
-**Pull**: Get the latest version of code from a reposity
99
99
100
-
-**Push**: Send your code changes to the repository
100
+
-**Push**: Send your code changes to the remote repository
101
101
102
-
-**Add**: Adds your chosen changes to the local Stage area, ready for a commit
102
+
-**Add**: Adds your chosen changes to the local Stage area, ready for a commit and push
103
103
104
104
-**Stage**: An index of changes you are preparing to commit to the repository
105
105
@@ -127,61 +127,10 @@ Try using messages such as _repositioned image to look better on page_ or _resol
127
127
When you come back to coding, be sure to `pull` any changes into your local repository that others may have committed to the repository since you last worked on the code. If there are changes you don't pull in you can get **Merge Conflicts**, where two sets of changes, the ones from other people and yours, need to be worked through to decide which change is kept. Resolving merge conflicts is notoriously tricky - small, frequent commits followed by a pull are a great way to avoid merge conflicts.
128
128
129
129
130
-
131
130
## The next step
132
131
133
132
Get set-up with [Git and GitHub](../set-up/tutorial.html).
134
133
135
-
136
-
---------- REMOVE FROM HERE ONWARDS -----------
137
-
138
-
## Now what?
139
-
140
-
Now that you have the Github client setup on your machine, we will spend some time adding what you have created in the HTML and CSS lessons to an internet repository! Before you start make sure the Github client is running and you are signed in.
141
-
142
-
1. Create a new repository by clicking the `Create New Repository` button
143
-
144
-

145
-
146
-
2. In your text editor, open the directory you just created and create a README.md file with the following content:
147
-
148
-
_This is where I store the work I have done at codebar._
149
-
150
-
3. Go back to the Github client and commit the file by filling out the `Summary` field and hitting the `Commit to master` button
151
-
152
-

153
-
154
-
4. Now, create a new branch called **gh-pages**
155
-
156
-

157
-
158
-
5. In the directory, create a subdirectory **lesson1** and move the **html** file you created at the first session and all the other relevant files and directories (e.g. /images)
159
-
160
-
6. Now, link the file from the root of your project by creating an `index.html` file and adding a link to the page
161
-
162
-
```
163
-
<a href='lesson1/index.html'>Lesson 1 - Introduction to HTML </a>
164
-
```
165
-
> Don't forget to rename index to whatever you have named your file!
166
-
167
-
7. Commit your changes to the gh-pages branch
168
-
169
-

170
-
171
-
8. Once you committed your changes publish your work by clicking the `Publish repository` button
To access your work, go to `http://<username>.github.io/codebar`
178
-
179
-
10. Repeat the process to list the rest of the tutorials you have worked on on the page as well.
180
-
181
-
## Bonus
182
-
183
-
This is your personal page. Use what you learned in the previous lessons to style it, make it look pretty, and what we learned today to commit and publish your changes.
184
-
185
134
-----
186
135
187
-
This ends our _Introduction to version control and git_ lesson. Is there something you don't understand? Try and go through the provided resources with your coach. If you have any feedback, or can think of ways to improve this tutorial [send us an email](mailto:[email protected]) and let us know.
136
+
This ends our **Introduction to version control with Git** lesson. Is there something you don't understand? Try and go through the provided resources with your coach. If you have any feedback, or can think of ways to improve this tutorial [send us an email](mailto:[email protected]) and let us know.
Copy file name to clipboardExpand all lines: version-control/set-up/tutorial.md
+24-9Lines changed: 24 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -3,6 +3,9 @@ layout: page
3
3
title: Set-up Git and GitHub
4
4
---
5
5
6
+
**PREREQUISITES:**
7
+
- Understanding of version control ([Introduction to Version Control and Git](../introduction/tutorial.html))
8
+
6
9
## Introduction to Git and GitHub
7
10
-----
8
11
Now that we know what Version Control is, let's get set-up with Git and Github. By the end of this tutorial we'll have installed Git, set-up a Github account, created SSH keys that we can use to authenticate between the two, then finally created and cloned a repository for us to start working on our own projects and contributing to others.
@@ -17,8 +20,6 @@ $ git --version
17
20
```
18
21
This will return the version of Git you've installed and prove it's up and running correctly.
19
22
20
-
> Later in the tutorial we'll download [Github Desktop](https://desktop.github.com/).
21
-
22
23
### Create an empty Git repository
23
24
Now create a directory where you will be storing all your projects, by typing the following lines and hitting enter after each. You can call the directory whatever you prefer, such as `code` or `projects`.
Now that we're all set-up with Git and Github, and we've set-up a folder on our local system that's been initiliased as a Git repository - we just need to add a remote repository on Github that we can commit our local files to.
141
+
142
+
In your home page on Github, click on `Repository` and then `New` to start adding a new repository.
143
+
144
+

138
145
139
-
Now that we're all set-up, we just need to add a repository on Github that we can add files to once we've crerated them on our local system.
146
+
On the next page complete the details for the `Respository name` and a `Description`. Set the visibility to `Public` and initialise with a README file so you can easily add a description and notes about the repository. It's recommended that you choose a license type too, MIT License is fairly common for open source work. When you're done, hit the `Create Respository` button.
140
147
141
-

148
+

142
149
143
-
### Clone a Github Respository
150
+
The respository will now be set-up with your readme and license files. It will also have a Github URL available to copy and use in Git when making a commit.
144
151
145
-
One last thing we can do for our set-up is to Clone a remote repository on Github, down to our local system.
152
+

146
153
147
-

154
+
For Git to know where we want files to go when we do a `git push` of items in our local respository, we need to add a reference to that repository. Enter the following command in a console window and be sure to add the URL you copied from Github.
148
155
156
+
```bash
157
+
$ git remote add origin <repository-url>
158
+
```
159
+
## The next step
160
+
161
+
Learn more about the [Git Command Line](../command-line/tutorial.html).
162
+
163
+
-----
149
164
150
-
This ends our _Set-up Git and GitHub_ lesson. Is there something you don't understand? Try and go through the provided resources with your coach. If you have any feedback or can think of ways to improve this tutorial [send us an email](mailto:[email protected]) and let us know.
165
+
This ends our **Set-up Git and GitHub** lesson. Is there something you don't understand? Try and go through the provided resources with your coach. If you have any feedback or can think of ways to improve this tutorial [send us an email](mailto:[email protected]) and let us know.
0 commit comments