Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .ruby-gemset
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
coffeescript-cookbook
1 change: 1 addition & 0 deletions .ruby-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1.9.3
12 changes: 6 additions & 6 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
source 'http://rubygems.org'
source 'https://rubygems.org'

group :development do
gem "RedCloth", "~> 4.2"
gem "foreman", "~> 0.13"
gem "serve", "~> 1.0"
gem "jekyll", "~> 0.10"
gem "thin", "~> 1.2"
gem "github-pages"
gem "tzinfo-data"

gem "foreman", "~> 0.63"
gem "serve", "~> 1.5"
end
98 changes: 64 additions & 34 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,47 +1,77 @@
GEM
remote: http://rubygems.org/
remote: https://rubygems.org/
specs:
RedCloth (4.2.9)
activesupport (3.0.7)
activesupport (3.2.14)
i18n (~> 0.6, >= 0.6.4)
multi_json (~> 1.0)
classifier (1.3.3)
fast-stemmer (>= 1.0.0)
daemons (1.1.3)
directory_watcher (1.4.0)
eventmachine (0.12.10)
fast-stemmer (1.0.0)
foreman (0.13.0)
term-ansicolor (~> 1.0.5)
colorator (0.1)
commander (4.1.5)
highline (~> 1.6.11)
directory_watcher (1.4.1)
dotenv (0.8.0)
fast-stemmer (1.0.2)
foreman (0.63.0)
dotenv (>= 0.7)
thor (>= 0.13.6)
i18n (0.4.2)
jekyll (0.10.0)
classifier (>= 1.3.1)
directory_watcher (>= 1.1.1)
liquid (>= 1.9.0)
maruku (>= 0.5.9)
liquid (2.2.2)
maruku (0.6.0)
github-pages (1)
RedCloth (= 4.2.9)
jekyll (= 1.1.2)
kramdown (= 1.0.2)
liquid (= 2.5.1)
maruku (= 0.6.1)
rdiscount (= 1.6.8)
redcarpet (= 2.2.2)
highline (1.6.19)
i18n (0.6.5)
jekyll (1.1.2)
classifier (~> 1.3)
colorator (~> 0.1)
commander (~> 4.1.3)
directory_watcher (~> 1.4.1)
kramdown (~> 1.0.2)
liquid (~> 2.5.1)
maruku (~> 0.5)
pygments.rb (~> 0.5.0)
redcarpet (~> 2.2.2)
safe_yaml (~> 0.7.0)
kramdown (1.0.2)
liquid (2.5.1)
maruku (0.6.1)
syntax (>= 1.0.0)
rack (1.2.2)
serve (1.0.0)
activesupport (~> 3.0.1)
i18n (~> 0.4.1)
rack (~> 1.2.1)
tzinfo (~> 0.3.23)
multi_json (1.7.9)
posix-spawn (0.3.6)
pygments.rb (0.5.2)
posix-spawn (~> 0.3.6)
yajl-ruby (~> 1.1.0)
rack (1.5.2)
rack-test (0.6.2)
rack (>= 1.0)
rdiscount (1.6.8)
redcarpet (2.2.2)
safe_yaml (0.7.1)
serve (1.5.2)
activesupport (~> 3.2.12)
i18n
rack (~> 1.5.2)
rack-test (~> 0.6.2)
tilt (~> 1.3.3)
tzinfo
syntax (1.0.0)
term-ansicolor (1.0.5)
thin (1.2.11)
daemons (>= 1.0.9)
eventmachine (>= 0.12.6)
rack (>= 1.0.0)
thor (0.14.6)
tzinfo (0.3.27)
thor (0.18.1)
tilt (1.3.7)
tzinfo (1.0.1)
tzinfo-data (1.2013.4)
tzinfo (>= 1.0.0)
yajl-ruby (1.1.0)

PLATFORMS
ruby

DEPENDENCIES
RedCloth (~> 4.2)
foreman (~> 0.13)
jekyll (~> 0.10)
serve (~> 1.0)
thin (~> 1.2)
foreman (~> 0.63)
github-pages
serve (~> 1.5)
tzinfo-data
2 changes: 1 addition & 1 deletion Procfile
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
jekyll: bundle exec jekyll --auto
jekyll: bundle exec jekyll build --watch
serve: bundle exec serve 4000 development _site
2 changes: 2 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
safe: true
pygments: true
lsi: false
markdown: redcarpet
exclude:
- README.md
- CNAME
Expand Down
54 changes: 24 additions & 30 deletions developers-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ _Please help out by updating this page_

### Operating System

It works on Mac OSX. Probably works without any changes or issues on linux. A masochist could probably get it working on Windows.
It works on Mac OSX. Probably works without any changes or issues on Linux.
A masochist could probably get it working on Windows.

## Installation

Expand All @@ -19,54 +20,47 @@ It works on Mac OSX. Probably works without any changes or issues on linux. A ma
git clone git://github.com/coffeescript-cookbook/coffeescript-cookbook.github.com.git
{% endhighlight %}

### Create a Ruby Gemset
### Ruby environment

Optional, but highly recommended.
You probably want to have [RVM](http://rvm.io/) installed.

{% highlight bash %}
$ rvm gemset create jekyll
$ echo 'rvm gemset use jekyll' >> .rvmrc
{% endhighlight %}

### Install Required Gems
The project includes a `.ruby-version` file locked to
*1.9.3* since that is what Github Pages are currently using.

{% highlight bash %}
gem install jekyll # needed for testing building the site
gem install RedCloth # needed for .md rendering
gem install serve # needed for resolving .html files w/o extension
gem install thin # optional; more efficient webserver than Webrick but not strictly necessary
{% endhighlight %}
There is also a `.ruby-gemset` that is set to *coffeescript-cookbook*

### Install pygments
### Required dependencies

You'll need python installed for this. Macs and most linuces come with it preinstalled.
We are using [Bundler](http://bundler.io/) to install the required Ruby dependencies.

{% highlight bash %}
easy_install pygments # for syntax highlighting
bundle install
{% endhighlight %}

## Building and Viewing the Website

### Run jekyll
#### Install pygments

Open a terminal window, cd into the project folder and run jekyll from the project root.
You'll need python installed for this.
Macs and most Linuces come with it preinstalled.

{% highlight bash %}
jekyll --auto
easy_install pygments # for syntax highlighting
{% endhighlight %}

Leave this window running while you work. Any time you change a file, jekyll will rerender it into the `_site` folder.

### Run serve
## Building and Viewing the Website

Open another terminal window, cd into the project folder, then cd into the `_site` subfolder, and run
Open a terminal window, cd into the project folder and run `foreman start` from the project root.

{% highlight bash %}
serve
foreman start
{% endhighlight %}

This will start a webserver in the `_site` folder. Open a browser and visit `http://localhost:4000/` and you should see the site.
Leave this window running while you work.
Any time you change a file, jekyll will rerender it into the `_site` folder.

Open a browser and visit <http://localhost:4000/> and you should see the site.

## Minutiae and Other Trivialities

jekyll can take a second or two to catch up when you save a file. If you edit a file and don't see the changes in your browser, give it a second or two and try again. You may also see Maruku warnings, but as long as it prints `Successfully generated site` you should be alright.
Jekyll can take a second or two to catch up when you save a file.
If you edit a file and don't see the changes in your browser, give it a second or two and try again.
As long as it prints `Successfully generated site` you should be alright.