Skip to content

Commit dc951a6

Browse files
committed
Fixed a couple of typos in c3s2
1 parent f1b0ec0 commit dc951a6

File tree

5 files changed

+7
-19
lines changed

5 files changed

+7
-19
lines changed

_sessions/c1s2/1_using_git.md

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,21 +6,7 @@ Git is a version control system. It allows you to keep the entire history of you
66

77
### Setting up a git repo
88

9-
Git works on a folder level. To set up a folder to work with git you need to navigate to that folder in the command line and run.
10-
11-
$ git init
12-
13-
To see what this has done do:
14-
15-
$ ls -a
16-
17-
The `-a` is a flag which tells the `ls` command to show hidden files and folders. You should see a folder called `.git` in the results. If you want you could move into this folder, and have a look around (and then move out again).
18-
19-
$ cd .git
20-
$ ls
21-
$ cd ..
22-
23-
All the data to allow git to version control your code will be stored inside this hidden folder. If you ever want to 'un-version-control' your code all you have to do is delete this folder.
9+
Git works on a folder level. To set up a folder to work with git you need to open up the github app and select `File > Add Local Repository ...`. You then need to select the folder you want to control with git.
2410

2511
### Excluding some files
2612

_sessions/c3s2/1_conditionals.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ else
1212
end
1313
{% endhighlight %}
1414

15-
If the code within the `if` block will only be run if the statement is true. If the statement is false, the code in the `else` block will be run instead.
15+
The code within the `if` block will only be run if the statement is true. If the statement is false, the code in the `else` block will be run instead.
1616

1717
### Comparisons
1818

19-
There are some basic comparisons that we will be useful when using if statments
19+
There are some basic comparisons that will be useful when using if statments
2020

2121
Symbol | Meaning
2222
---- | ----

_sessions/c3s2/2_post_requests.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,5 @@ Note that, like the words matched in the url, the value of the `user_name` field
4141
2. Clone down your fork of the repository onto your laptop.
4242
3. Open the `sinatra_c3s2` project in Sublime Text and have a read through `app.rb`. See if you can predict what the app will do.
4343
4. Run the app from the command line (`ruby app.rb`), to see if you were right.
44+
5. (Optional) Add the line `raise params.inspect` right at the top of the post block. Restart the app and see what happens.
4445
{% endexercise %}

_sessions/c3s2/3_deploying.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ Deploy your `sinatra_c3s2` app to Heroku:
107107
2. Add your work (and new `Gemfile.lock`) to your repository:
108108

109109
$ git add --all
110-
$ git commit -m "Added Gemfile.lock"
110+
$ git commit -m 'Added Gemfile.lock'
111111

112112
3. Create a new heroku app:
113113

_sessions/c3s2/4_templates.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ end
3737

3838
The line `erb :form` tells sinatra to look for a file called `form.erb` in a folder called `views`. It then processes that file using the `erb` (embedded ruby) templating language and returns the result to the user.
3939

40-
The `form.erb` above isn't very interesting: it is jsut a static template and doesn't have any ruby embedded in it. Let's look at a slightly better example:
40+
The `form.erb` above isn't very interesting: it is just a static template and doesn't have any ruby embedded in it. Let's look at a slightly better example:
4141

4242
{% highlight ruby %}
4343
# in app.rb
@@ -50,6 +50,7 @@ post '/' do
5050
@age = params[:user_age]
5151

5252
erb :welcome
53+
end
5354
{% endhighlight %}
5455

5556
{% highlight html %}

0 commit comments

Comments
 (0)