From 8a97e530b3983ebbf4789ffbb0c41eba33201948 Mon Sep 17 00:00:00 2001 From: kendocode Date: Thu, 15 Nov 2018 14:06:50 -0600 Subject: [PATCH 01/35] Update ruby_short version string to Heroku minimum Student for upcoming Railsbridge Tulsa event reports unable to use Heroku with recommended Ruby version of 2.3. Heroku current minimum version is 2.3.8. We suggested trying latest, and user reports no problems with 2.5.3. --- lib/site_extensions/installfest.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/site_extensions/installfest.rb b/lib/site_extensions/installfest.rb index 4b4924dfd..08c157d68 100644 --- a/lib/site_extensions/installfest.rb +++ b/lib/site_extensions/installfest.rb @@ -3,7 +3,7 @@ module Installfest def version_string(name) case name when :ruby_short - '2.3' + '2.3.8' when :windows_rubygems_min '2.6.7' when :windows_rubygems_min_short @@ -13,4 +13,4 @@ def version_string(name) end end end -end \ No newline at end of file +end From 11247abbbd211660679d29b4a7e99a091c6b117d Mon Sep 17 00:00:00 2001 From: Matt Luker Date: Wed, 10 Jul 2019 15:59:08 -0500 Subject: [PATCH 02/35] Update correct link for mvc diagram --- sites/en/workshop/diagrams.mw | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sites/en/workshop/diagrams.mw b/sites/en/workshop/diagrams.mw index 3651c174a..f32b9112e 100644 --- a/sites/en/workshop/diagrams.mw +++ b/sites/en/workshop/diagrams.mw @@ -2,7 +2,7 @@ * MVC: http://github.com/alexch/mission/raw/master/mvc.png -* MVC: https://www.railstutorial.org/book/demo_app#sec-mvc_in_action +* MVC: https://www.railstutorial.org/book/toy_app#sec-exercises_mvc_in_action * REST: From 943611f035ca292082c05b3262ab4abb74085bb6 Mon Sep 17 00:00:00 2001 From: cuchalin <57273909+cuchalin@users.noreply.github.com> Date: Wed, 13 Nov 2019 02:02:29 -0800 Subject: [PATCH 03/35] added missing commas MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ‘Hopefully, it addressed most of your concerns about git,…’ --- added comma after Hopefully ‘In order to contribute, you’ll need to be able to familiarize yourself…’ ---added comma after contribute --- CONTRIBUTING.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e53b2f993..937117101 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -69,7 +69,7 @@ maintainers to love you. :heart:* # It's My First Time on GitHub Ever What Do I Do? -Relax, you came to the right place. In order to contribute you'll need to be +Relax, you came to the right place. In order to contribute, you'll need to be able to familiarize yourself with some concepts from git and GitHub. It's going to be a lot of information, but you're :sparkles:awesome:sparkles:! So you'll be fine. @@ -100,7 +100,7 @@ at . Do it. It's worth it no matter how much git-fu you Also, [Pro Git](http://git-scm.com/book) is a great (and free!) book about Git. -We apologize for how long this document is! Hopefully it addressed +We apologize for how long this document is! Hopefully, it addressed most of your concerns about git, contributing, and GitHub. Feel free to ask more questions on the [railsbridge-workshops](http://groups.google.com/group/railsbridge-workshops) From 396d975da638728dde7160398f510aa9497b9f46 Mon Sep 17 00:00:00 2001 From: Jonas Pfannkuche Date: Tue, 7 Dec 2021 19:40:27 +0100 Subject: [PATCH 04/35] Update job board update list step Replace deprecated "update_attributes" with "update". --- sites/en/job-board/update_job_listings.step | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sites/en/job-board/update_job_listings.step b/sites/en/job-board/update_job_listings.step index 23a5c280f..52ceb2803 100644 --- a/sites/en/job-board/update_job_listings.step +++ b/sites/en/job-board/update_job_listings.step @@ -148,7 +148,7 @@ source_code_with_message "Here's what the update method should actually look lik <<-RUBY def update @job = Job.find(params[:id]) - @job.update_attributes(job_params) + @job.update(job_params) redirect_to jobs_path end RUBY From 116dfe20b5d7131a4717f2fcbff57e457eb23cf5 Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Fri, 25 Feb 2022 11:51:05 -0600 Subject: [PATCH 05/35] Upgrade Ruby version and dependencies There are probable more gems than need to be updated, but this was the minimum set that allowed me to upgrade to Ruby 2.7.5 * Upgrade Ruby to 2.7.5 * Upgrade thin to 1.8.1 * Upgrade ffi to 1.15.5 * Upgrade backports to 3.23.0 * Upgrade bundler version to 2.3.8 --- Gemfile | 6 ++++-- Gemfile.lock | 14 ++++++++------ 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/Gemfile b/Gemfile index a9b60be45..ab6a5ab0e 100644 --- a/Gemfile +++ b/Gemfile @@ -1,13 +1,13 @@ source "https://rubygems.org/" -ruby '2.3.3' +ruby '2.7.5' gem 'activesupport' gem "erector", "~> 0.10.0" gem "sinatra", "~> 1.4.0" gem "sinatra-contrib", "~> 1.4.0" gem "nokogiri" -gem "thin" +gem "thin", "1.8.1" gem 'rack-codehighlighter' gem 'coderay' gem "deckrb", "~> 0.5.2" @@ -19,6 +19,8 @@ gem 'font-awesome-sass' gem 'bootstrap-sass' gem 'jquery-cdn' gem 'sprockets' +gem 'ffi', "1.15.5" +gem 'backports', "3.23.0" group :development do gem "rspec" diff --git a/Gemfile.lock b/Gemfile.lock index 20819727d..4a14801cf 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -8,7 +8,7 @@ GEM tzinfo (~> 1.1) autoprefixer-rails (6.7.7) execjs - backports (3.6.8) + backports (3.23.0) bootstrap-sass (3.3.7) autoprefixer-rails (>= 5.2.1) sass (>= 3.3.4) @@ -30,7 +30,7 @@ GEM treetop (>= 1.2.3) eventmachine (1.2.3) execjs (2.7.0) - ffi (1.9.18) + ffi (1.15.5) files (0.3.1) font-awesome-sass (4.7.0) sass (>= 3.2) @@ -93,7 +93,7 @@ GEM sprockets (3.7.1) concurrent-ruby (~> 1.0) rack (> 1, < 3) - thin (1.7.0) + thin (1.8.1) daemons (~> 1.0, >= 1.0.9) eventmachine (~> 1.0, >= 1.0.4) rack (>= 1, < 3) @@ -110,10 +110,12 @@ PLATFORMS DEPENDENCIES activesupport + backports (= 3.23.0) bootstrap-sass coderay deckrb (~> 0.5.2) erector (~> 0.10.0) + ffi (= 1.15.5) files (~> 0.3.0) font-awesome-sass i18n (~> 0.7) @@ -131,10 +133,10 @@ DEPENDENCIES sinatra (~> 1.4.0) sinatra-contrib (~> 1.4.0) sprockets - thin + thin (= 1.8.1) RUBY VERSION - ruby 2.3.3p222 + ruby 2.7.5p203 BUNDLED WITH - 1.14.3 + 2.3.8 From 592fec9f88fe7a614347a11deece34ce6eeb46ac Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Fri, 4 Mar 2022 10:47:55 -0600 Subject: [PATCH 06/35] Update .ruby-version file --- .ruby-version | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.ruby-version b/.ruby-version index 0bee604df..a603bb50a 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.3.3 +2.7.5 From 9cca509d32d3be2f55ff3e590aba663803bac754 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 9 Mar 2022 18:02:17 +0000 Subject: [PATCH 07/35] Bump activesupport from 5.0.2 to 5.2.4.3 Bumps [activesupport](https://github.com/rails/rails) from 5.0.2 to 5.2.4.3. - [Release notes](https://github.com/rails/rails/releases) - [Changelog](https://github.com/rails/rails/blob/v6.0.3.1/activesupport/CHANGELOG.md) - [Commits](https://github.com/rails/rails/compare/v5.0.2...v5.2.4.3) Signed-off-by: dependabot[bot] --- Gemfile.lock | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 4a14801cf..2f092152a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,9 +1,9 @@ GEM remote: https://rubygems.org/ specs: - activesupport (5.0.2) + activesupport (5.2.4.3) concurrent-ruby (~> 1.0, >= 1.0.2) - i18n (~> 0.7) + i18n (>= 0.7, < 2) minitest (~> 5.1) tzinfo (~> 1.1) autoprefixer-rails (6.7.7) @@ -13,7 +13,7 @@ GEM autoprefixer-rails (>= 5.2.1) sass (>= 3.3.4) coderay (1.1.1) - concurrent-ruby (1.0.5) + concurrent-ruby (1.1.9) daemons (1.2.4) deckrb (0.5.2) coderay @@ -43,7 +43,7 @@ GEM rb-inotify (~> 0.9, >= 0.9.7) ruby_dep (~> 1.2) mini_portile2 (2.1.0) - minitest (5.10.1) + minitest (5.15.0) multi_json (1.12.1) nokogiri (1.7.0.1) mini_portile2 (~> 2.1.0) @@ -102,7 +102,7 @@ GEM treetop (1.6.8) polyglot (~> 0.3) trollop (2.1.2) - tzinfo (1.2.2) + tzinfo (1.2.9) thread_safe (~> 0.1) PLATFORMS From 1071f0b77efaa88a16b557e8b98d5daa71ab5351 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:15:05 +0000 Subject: [PATCH 08/35] Bump rubyzip from 1.2.1 to 1.3.0 Bumps [rubyzip](https://github.com/rubyzip/rubyzip) from 1.2.1 to 1.3.0. - [Release notes](https://github.com/rubyzip/rubyzip/releases) - [Changelog](https://github.com/rubyzip/rubyzip/blob/master/Changelog.md) - [Commits](https://github.com/rubyzip/rubyzip/compare/v1.2.1...v1.3.0) Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 4a14801cf..a6f638c4b 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -77,7 +77,7 @@ GEM rspec-support (~> 3.5.0) rspec-support (3.5.0) ruby_dep (1.5.0) - rubyzip (1.2.1) + rubyzip (1.3.0) sass (3.4.23) sinatra (1.4.8) rack (~> 1.5) From a3b54853fb999bafbfb00d0689edccad34275d92 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:17:27 +0000 Subject: [PATCH 09/35] Bump rake from 12.0.0 to 12.3.3 Bumps [rake](https://github.com/ruby/rake) from 12.0.0 to 12.3.3. - [Release notes](https://github.com/ruby/rake/releases) - [Changelog](https://github.com/ruby/rake/blob/master/History.rdoc) - [Commits](https://github.com/ruby/rake/compare/v12.0.0...v12.3.3) Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index a6f638c4b..65f085b47 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -56,7 +56,7 @@ GEM rack rack-test (0.6.3) rack (>= 1.0) - rake (12.0.0) + rake (12.3.3) rb-fsevent (0.9.8) rb-inotify (0.9.8) ffi (>= 0.5.0) From ac1183217a856fbb2dfcea568858341bcb0e9d9b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:19:49 +0000 Subject: [PATCH 10/35] Bump rack from 1.6.5 to 1.6.13 Bumps [rack](https://github.com/rack/rack) from 1.6.5 to 1.6.13. - [Release notes](https://github.com/rack/rack/releases) - [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md) - [Commits](https://github.com/rack/rack/compare/1.6.5...1.6.13) --- updated-dependencies: - dependency-name: rack dependency-type: indirect ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index f43c37337..74ede6ab4 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -48,7 +48,7 @@ GEM nokogiri (1.7.0.1) mini_portile2 (~> 2.1.0) polyglot (0.3.5) - rack (1.6.5) + rack (1.6.13) rack-codehighlighter (0.5.1) nokogiri (>= 1.4.1) rack (>= 1.0.0) From 41bf9190de32de4948d56882ce28593fc76488b0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:20:10 +0000 Subject: [PATCH 11/35] Bump json from 2.0.3 to 2.6.1 Bumps [json](https://github.com/flori/json) from 2.0.3 to 2.6.1. - [Release notes](https://github.com/flori/json/releases) - [Changelog](https://github.com/flori/json/blob/master/CHANGES.md) - [Commits](https://github.com/flori/json/compare/v2.0.3...v2.6.1) --- updated-dependencies: - dependency-name: json dependency-type: indirect ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index f43c37337..fbaa6ae2a 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -37,7 +37,7 @@ GEM i18n (0.8.1) jquery-cdn (2.2.4) sprockets (>= 2) - json (2.0.3) + json (2.6.1) listen (3.1.5) rb-fsevent (~> 0.9, >= 0.9.4) rb-inotify (~> 0.9, >= 0.9.7) From 18a3b636a299d8723b2d91bcb7507f2b85a3b9ed Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:21:38 +0000 Subject: [PATCH 12/35] Bump nokogiri from 1.7.0.1 to 1.13.2 Bumps [nokogiri](https://github.com/sparklemotion/nokogiri) from 1.7.0.1 to 1.13.2. - [Release notes](https://github.com/sparklemotion/nokogiri/releases) - [Changelog](https://github.com/sparklemotion/nokogiri/blob/main/CHANGELOG.md) - [Commits](https://github.com/sparklemotion/nokogiri/compare/v1.7.0.1...v1.13.2) --- updated-dependencies: - dependency-name: nokogiri dependency-type: direct:production ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 19979f0cf..e9a6e8ebd 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -42,12 +42,14 @@ GEM rb-fsevent (~> 0.9, >= 0.9.4) rb-inotify (~> 0.9, >= 0.9.7) ruby_dep (~> 1.2) - mini_portile2 (2.1.0) + mini_portile2 (2.8.0) minitest (5.15.0) multi_json (1.12.1) - nokogiri (1.7.0.1) - mini_portile2 (~> 2.1.0) + nokogiri (1.13.2) + mini_portile2 (~> 2.8.0) + racc (~> 1.4) polyglot (0.3.5) + racc (1.6.0) rack (1.6.13) rack-codehighlighter (0.5.1) nokogiri (>= 1.4.1) From 92cf32f3efc1081664960bdb4657e7dfe7cc6754 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:21:47 +0000 Subject: [PATCH 13/35] Bump bootstrap-sass from 3.3.7 to 3.4.1 Bumps [bootstrap-sass](https://github.com/twbs/bootstrap-sass) from 3.3.7 to 3.4.1. - [Release notes](https://github.com/twbs/bootstrap-sass/releases) - [Changelog](https://github.com/twbs/bootstrap-sass/blob/master/CHANGELOG.md) - [Commits](https://github.com/twbs/bootstrap-sass/compare/v3.3.7...v3.4.1) --- updated-dependencies: - dependency-name: bootstrap-sass dependency-type: direct:production ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 19979f0cf..958ee55ac 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -6,12 +6,12 @@ GEM i18n (>= 0.7, < 2) minitest (~> 5.1) tzinfo (~> 1.1) - autoprefixer-rails (6.7.7) - execjs + autoprefixer-rails (10.4.2.0) + execjs (~> 2) backports (3.23.0) - bootstrap-sass (3.3.7) + bootstrap-sass (3.4.1) autoprefixer-rails (>= 5.2.1) - sass (>= 3.3.4) + sassc (>= 2.0.0) coderay (1.1.1) concurrent-ruby (1.1.9) daemons (1.2.4) @@ -29,7 +29,7 @@ GEM erector (0.10.0) treetop (>= 1.2.3) eventmachine (1.2.3) - execjs (2.7.0) + execjs (2.8.1) ffi (1.15.5) files (0.3.1) font-awesome-sass (4.7.0) @@ -79,6 +79,8 @@ GEM ruby_dep (1.5.0) rubyzip (1.3.0) sass (3.4.23) + sassc (2.4.0) + ffi (~> 1.9) sinatra (1.4.8) rack (~> 1.5) rack-protection (~> 1.4) From 7dcd153d7b305da9f6129590fcaa5c7db36dbca9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:23:39 +0000 Subject: [PATCH 14/35] Bump rack-protection from 1.5.3 to 1.5.5 Bumps [rack-protection](https://github.com/sinatra/sinatra) from 1.5.3 to 1.5.5. - [Release notes](https://github.com/sinatra/sinatra/releases) - [Changelog](https://github.com/sinatra/sinatra/blob/master/CHANGELOG.md) - [Commits](https://github.com/sinatra/sinatra/commits) --- updated-dependencies: - dependency-name: rack-protection dependency-type: indirect ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 63376a0b0..3e75a944f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -54,7 +54,7 @@ GEM rack-codehighlighter (0.5.1) nokogiri (>= 1.4.1) rack (>= 1.0.0) - rack-protection (1.5.3) + rack-protection (1.5.5) rack rack-test (0.6.3) rack (>= 1.0) From bf48bd2f242e06ff60a015841fbbe9a968db0eab Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Mar 2022 01:23:41 +0000 Subject: [PATCH 15/35] Bump sprockets from 3.7.1 to 3.7.2 Bumps [sprockets](https://github.com/rails/sprockets) from 3.7.1 to 3.7.2. - [Release notes](https://github.com/rails/sprockets/releases) - [Changelog](https://github.com/rails/sprockets/blob/v3.7.2/CHANGELOG.md) - [Commits](https://github.com/rails/sprockets/compare/v3.7.1...v3.7.2) --- updated-dependencies: - dependency-name: sprockets dependency-type: direct:production ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index 63376a0b0..ad86ca7c2 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -94,7 +94,7 @@ GEM rack-test sinatra (~> 1.4.0) tilt (>= 1.3, < 3) - sprockets (3.7.1) + sprockets (3.7.2) concurrent-ruby (~> 1.0) rack (> 1, < 3) thin (1.8.1) From d957d7a60870620e0ffa01ea86fcffdbc4436223 Mon Sep 17 00:00:00 2001 From: Fiona Tang <79673633+fionatagious@users.noreply.github.com> Date: Sun, 18 Apr 2021 21:30:43 -0700 Subject: [PATCH 16/35] change "master" language to "main" --- sites/en/intro-to-rails/_deploying_to_heroku_again.step | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sites/en/intro-to-rails/_deploying_to_heroku_again.step b/sites/en/intro-to-rails/_deploying_to_heroku_again.step index 42426cb7f..753f43c7a 100644 --- a/sites/en/intro-to-rails/_deploying_to_heroku_again.step +++ b/sites/en/intro-to-rails/_deploying_to_heroku_again.step @@ -12,7 +12,7 @@ changes are: something like \"Added votes to the topics index\"." end step "Push changes to Heroku" do - console "git push heroku master" + console "git push heroku main" message "This takes all changes you've committed locally and pushes them to Heroku." end @@ -57,5 +57,5 @@ required updating the `Gemfile` and bundling. li { message "Commit your changes (`git commit`)" } li { message "(repeat)" } end - message "Any time your changes are committed, you should feel free to `git push heroku master` and boom! Your changes are live!" + message "Any time your changes are committed, you should feel free to `git push heroku main` and boom! Your changes are live!" end From e3722adea70666cb59cf5154db55364244d8c48f Mon Sep 17 00:00:00 2001 From: Fernando Date: Fri, 1 Apr 2022 12:24:31 -0600 Subject: [PATCH 17/35] Move localization from directory-based to i18n-based This commit removes the need of having an specific folder per language inside /docs With only one top-level doc, we can handle translations on their corresponding files now living under locales Each language now has its own folder, which is going to make easier to implement continuos localization with Crowdin --- app.rb | 183 ++++++++---------- lib/site.rb | 27 ++- lib/site_index.rb | 2 +- locales/en.yml | 34 ---- locales/en/captions.yml | 7 + locales/en/general.yml | 14 ++ locales/en/header_sections.yml | 10 + locales/en/sites.yml | 3 + locales/es/captions.yml | 7 + locales/es/general.yml | 14 ++ locales/es/header_sections.yml | 10 + locales/es/sites.yml | 3 + locales/zh-tw/captions.yml | 7 + locales/zh-tw/general.yml | 14 ++ locales/zh-tw/header_section.yml | 10 + sites/{en => }/docs/docs.step | 0 sites/es/hola/hola.step | 1 - sites/{en => }/frontend/HTML_attributes.step | 0 sites/{en => }/frontend/HTML_structure.step | 0 sites/{en => }/frontend/HTML_tags.step | 0 .../_consider_deploying_to_github.step | 0 .../_consider_deploying_to_github_again.step | 0 sites/{en => }/frontend/_developer_tools.step | 0 .../_working_effectively_and_efficiently.md | 0 .../{en => }/frontend/add_more_elements.step | 0 .../{en => }/frontend/add_starter_files.step | 0 sites/{en => }/frontend/basic_CSS.step | 0 sites/{en => }/frontend/basic_javascript.step | 0 .../frontend/deploying_to_github.step | 0 .../frontend/deploying_to_github_again.step | 0 sites/{en => }/frontend/developer_tools.step | 0 .../frontend/front-end-lesson.zip-manifest | 0 sites/{en => }/frontend/frontend.step | 0 sites/{en => }/frontend/get_a_sticker.step | 0 sites/{en => }/frontend/grid.html | 0 .../frontend/griding_with_bootstrap.step | 0 .../{en => }/frontend/html_quick_reference.md | 0 sites/{en => }/frontend/img/boxmodel.png | Bin sites/{en => }/frontend/img/css.png | Bin sites/{en => }/frontend/img/css_bundler.png | Bin sites/{en => }/frontend/img/css_class.png | Bin sites/{en => }/frontend/img/css_id.png | Bin sites/{en => }/frontend/img/css_zen.png | Bin sites/{en => }/frontend/img/devtools.png | Bin .../frontend/img/devtools_console.png | Bin .../frontend/img/devtools_elements.png | Bin .../frontend/img/devtools_network.png | Bin .../{en => }/frontend/img/devtools_script.png | Bin .../img/get_a_sticker_fork_button.png | Bin .../frontend/img/get_a_sticker_https.png | Bin .../frontend/img/get_a_sticker_output.png | Bin .../frontend/img/github_create_repo.png | Bin .../frontend/img/github_name_your_repo.png | Bin sites/{en => }/frontend/img/hello_html.png | Bin sites/{en => }/frontend/img/hello_omg.png | Bin .../{en => }/frontend/img/hello_structure.png | Bin sites/{en => }/frontend/img/hello_style.png | Bin sites/{en => }/frontend/img/hello_title.png | Bin sites/{en => }/frontend/img/hello_world.png | Bin .../frontend/img/hello_world_2line.png | Bin .../frontend/img/hello_world_2line2.png | Bin .../frontend/img/hello_world_jazzy.png | Bin .../{en => }/frontend/img/html_tags_list.png | Bin sites/{en => }/frontend/img/jquery_result.png | Bin sites/{en => }/frontend/img/page.png | Bin sites/{en => }/frontend/img/page_anchors.png | Bin sites/{en => }/frontend/img/page_html.png | Bin sites/{en => }/frontend/img/page_img.png | Bin sites/{en => }/frontend/img/page_sample.jpg | Bin sites/{en => }/frontend/img/prompt.png | Bin sites/{en => }/frontend/img/zip.png | Bin .../frontend/introduction_to_html.step | 0 sites/{en => }/frontend/jquery.step | 0 .../frontend/jquery_vs_javascript.step | 0 sites/{en => }/frontend/make_a_web_page.step | 0 sites/{en => }/frontend/make_columns.step | 0 sites/{en => }/frontend/resources.step | 0 .../{en => }/frontend/tool_installation.step | 0 .../{en => }/frontend/zip_content/.gitignore | 0 .../{en => }/frontend/zip_content/index.html | 0 .../zip_content/resources/javascript.js | 0 .../frontend/zip_content/resources/layout.css | 0 .../zip_content/resources/picture.jpg | Bin .../installfest/_command-line-glossary.md | 0 .../{en => }/installfest/_general-glossary.md | 0 .../installfest/_install_atom_for_mac.step | 0 .../installfest/_install_homebrew.step | 0 sites/{en => }/installfest/_install_ruby.step | 0 sites/{en => }/installfest/_install_rvm.step | 0 .../installfest/_install_textmate.step | 0 .../installfest/_ruby-and-rails-glossary.md | 0 .../_switch_to_home_directory.step | 0 .../choose_your_operating_system.step | 0 sites/{en => }/installfest/clean_up.step | 0 sites/{en => }/installfest/configure_git.step | 0 .../installfest/create_a_github_account.step | 0 .../installfest/create_a_heroku_account.step | 0 .../installfest/create_a_rails_app.step | 0 .../installfest/create_an_ssh_key.step | 0 .../installfest/deploy_a_rails_app.step | 0 sites/{en => }/installfest/editors.step | 0 sites/{en => }/installfest/get_a_sticker.step | 0 sites/{en => }/installfest/glossary.step | 0 .../{en => }/installfest/img/AboutThisMac.png | Bin .../installfest/img/WinRailsInstaller.jpg | Bin sites/{en => }/installfest/img/appstore.jpg | Bin sites/{en => }/installfest/img/directory.png | Bin .../img/get_a_sticker_you_should_see.png | Bin .../installfest/img/install_atom_mac.gif | Bin .../img/railsbridge_ubuntu12-checkbox.png | Bin ...reenshot-commandprompt-pinnedtotaskbar.png | Bin ...ge_windowsScreenshot-commandprompt_ror.png | Bin ...idge_windows_findingCommandPrompt_win7.png | Bin ...idge_windows_findingCommandPrompt_win8.png | Bin .../img/successful_rails_install.png | Bin .../{en => }/installfest/img/xcode-prefs.jpg | Bin .../installfest/img/xcode-tools-install.png | Bin sites/{en => }/installfest/install_xcode.step | 0 .../install_xcode_command_line_tools.step | 0 .../install_xcode_from_app_store.step | 0 .../installfest/install_xcode_from_dvd.step | 0 sites/{en => }/installfest/installfest.step | 0 sites/{en => }/installfest/linux.step | 0 sites/{en => }/installfest/macOS.step | 0 sites/{en => }/installfest/osx_rvm.step | 0 sites/{en => }/installfest/windows.step | 0 .../intro-to-rails/CRUD_with_scaffolding.step | 0 .../intro-to-rails/_consider_deploying.step | 0 .../_consider_deploying_again.step | 0 .../intro-to-rails/_deploying_to_heroku.step | 0 .../_deploying_to_heroku_again.step | 0 .../_switch_to_home_directory.step | 0 .../_working_effectively_and_efficiently.md | 0 .../add_the_project_to_a_git_repo.step | 0 .../intro-to-rails/allow_people_to_vote.step | 0 .../clean_up_links_on_the_topics_list.step | 0 .../intro-to-rails/creating_a_migration.step | 0 .../credits_and_next_steps.step | 0 .../intro-to-rails/deploying_to_heroku.step | 0 .../deploying_to_heroku_again.step | 0 .../intro-to-rails/getting_started.step | 0 sites/{en => }/intro-to-rails/glossary.step | 0 .../hooking_up_votes_and_topics.step | 0 .../img/Seattle_list_with_topic.png | Bin .../img/Seattle_topic_created.png | Bin .../img/Seattle_topic_list_page.png | Bin .../intro-to-rails/img/Start_page.png | Bin .../img/atom_add_folder_to_project.png | Bin .../img/atom_project_as_folder.png | Bin .../intro-to-rails/img/finished_app.png | Bin sites/{en => }/intro-to-rails/img/mvc.png | Bin .../img/rails4_rails_info_routing.png | Bin .../{en => }/intro-to-rails/img/workflow.png | Bin .../intro-to-rails/intro-to-rails.step | 0 .../make_the_topic_title_a_link.step | 0 .../intro-to-rails/rails_architecture.step | 0 ...opics_list_after_creating_a_new_topic.step | 0 .../intro-to-rails/ruby_language.step | 0 .../running_your_application_locally.step | 0 .../setting_the_default_page.step | 0 .../intro-to-rails/voting_on_topics.step | 0 .../img/browser_console.png | Bin .../javascript-snake-game.step | 0 .../js-snake-game-tutorial.zip-manifest | 0 .../javascript-snake-game/js/chunk.js | 0 .../javascript-snake-game/js/lesson-10.js | 0 .../javascript-snake-game/js/lesson-11.js | 0 .../javascript-snake-game/js/lesson-12.js | 0 .../javascript-snake-game/js/lesson-13.js | 0 .../javascript-snake-game/js/lesson-2.js | 0 .../javascript-snake-game/js/lesson-3.js | 0 .../javascript-snake-game/js/lesson-4.js | 0 .../javascript-snake-game/js/lesson-5.js | 0 .../javascript-snake-game/js/lesson-6.js | 0 .../javascript-snake-game/js/lesson-7.js | 0 .../javascript-snake-game/js/lesson-8.js | 0 .../javascript-snake-game/js/lesson-9.js | 0 .../javascript-snake-game/js/snake.js | 0 .../javascript-snake-game/lesson-1.step | 0 .../javascript-snake-game/lesson-10.step | 0 .../javascript-snake-game/lesson-11.step | 0 .../javascript-snake-game/lesson-12.step | 0 .../javascript-snake-game/lesson-13.step | 0 .../javascript-snake-game/lesson-14.step | 0 .../javascript-snake-game/lesson-2.step | 0 .../javascript-snake-game/lesson-3.step | 0 .../javascript-snake-game/lesson-4.step | 0 .../javascript-snake-game/lesson-5.step | 0 .../javascript-snake-game/lesson-6.step | 0 .../javascript-snake-game/lesson-7.step | 0 .../javascript-snake-game/lesson-8.step | 0 .../javascript-snake-game/lesson-9.step | 0 .../zip_content/index.html | 0 .../zip_content/snake.js | 0 .../AdvancedTodoList.zip-manifest | 0 .../adding_an_item.step | 0 ...lding_complex_applications_with_react.step | 0 .../creating_a_list.step | 0 .../deploying_your_site.step | 0 .../developer_tools.step | 0 .../javascript-to-do-list-with-react.step | 0 .../loading_items.step | 0 .../marking_an_item_as_complete.step | 0 .../next_steps.step | 0 .../zip_content/app.js | 0 .../zip_content/console-polyfill.js | 0 .../zip_content/debut_light.png | Bin .../zip_content/index.html | 0 .../zip_content/store.js | 0 .../zip_content/styles.css | 0 .../IntermediateTodoList.zip-manifest | 0 .../_deploying_your_site.md | 0 .../javascript-to-do-list/_lesson_format.md | 0 .../javascript-to-do-list/_teachers_note.md | 0 .../javascript-to-do-list/adding_an_item.step | 0 .../creating_a_list.step | 0 .../deploying_your_site.step | 0 .../developer_tools.step | 0 .../img/browser_console.png | Bin .../img/finished_app.png | Bin .../javascript-to-do-list/img/network_tab.png | Bin .../img/text_editor_html.png | Bin .../javascript-to-do-list.step | 0 .../javascript-to-do-list/loading_items.step | 0 .../marking_an_item_as_complete.step | 0 .../javascript-to-do-list/next_steps.step | 0 .../playing_with_jquery.step | 0 .../programming_with_javascript.step | 0 .../the_basics_of_a_website.step | 0 .../javascript-to-do-list/zip_content/app.js | 0 .../zip_content/debut_light.png | Bin .../zip_content/index.html | 0 .../zip_content/styles.css | 0 sites/{en => }/job-board/add_a_navbar.step | 0 .../job-board/add_a_new_job_form.step | 0 sites/{en => }/job-board/add_more_things.step | 0 .../job-board/create_a_rails_app.step | 0 .../crud_and_resourceful_routing.step | 0 .../job-board/delete_job_listings.step | 0 sites/{en => }/job-board/img/crud_grid.jpg | Bin .../job-board/img/crud_rails_methods.jpg | Bin sites/{en => }/job-board/img/rails-routes.png | Bin .../{en => }/job-board/img/request-cycle.jpg | Bin sites/{en => }/job-board/job-board.step | 0 .../{en => }/job-board/listing_the_jobs.step | 0 .../job-board/make_a_jobs_home_page.step | 0 .../job-board/make_the_form_work.step | 0 .../job-board/store_jobs_in_the_database.step | 0 .../{en => }/job-board/the_request_cycle.step | 0 .../job-board/update_job_listings.step | 0 sites/{en => }/learn-to-code/argv.md | 0 sites/{en => }/learn-to-code/arrays.md | 0 sites/{en => }/learn-to-code/computers.md | 0 sites/{en => }/learn-to-code/extra.md | 0 sites/{en => }/learn-to-code/functions.md | 0 sites/{en => }/learn-to-code/hashes.md | 0 .../learn-to-code/img/cookie-recipe.gif | Bin sites/{en => }/learn-to-code/img/dot.jpg | Bin .../img/fruit-banana-snack-banana.svg | 0 .../learn-to-code/img/one-infinite-loop.jpg | Bin .../learn-to-code/img/snack-apple.svg | 0 .../learn-to-code/img/snack-fruit.svg | 0 sites/{en => }/learn-to-code/img/spoon.jpg | Bin .../{en => }/learn-to-code/img/truthiness.png | Bin .../{en => }/learn-to-code/img/warehouse.jpg | Bin .../learn-to-code/img/wargames-terminal.jpg | Bin .../learn-to-code/input_and_output.md | 0 sites/{en => }/learn-to-code/learn-to-code.md | 0 sites/{en => }/learn-to-code/logic.md | 0 sites/{en => }/learn-to-code/loops.md | 0 sites/{en => }/learn-to-code/methods.md | 0 sites/{en => }/learn-to-code/next_steps.md | 0 sites/{en => }/learn-to-code/nil.md | 0 sites/{en => }/learn-to-code/numbers.md | 0 sites/{en => }/learn-to-code/objects.md | 0 sites/{en => }/learn-to-code/sinatra.md | 0 sites/{en => }/learn-to-code/strings.md | 0 .../learn-to-code/the_command_line.md | 0 .../learn-to-code/todo-learntocode.md | 0 sites/{en => }/learn-to-code/variables.md | 0 .../add_other_features_of_your_choosing.step | 0 ...o_create_and_look_at_individual_posts.step | 0 .../{en => }/message-board/add_replying.step | 0 sites/{en => }/message-board/commands.md | 0 ...new_rails_app_with_a_static_home_page.step | 0 .../creating_a_new_controller.md | 0 .../message-board/img/create_post.png | Bin .../message-board/img/create_reply.png | Bin sites/{en => }/message-board/img/header.png | Bin .../message-board/img/inline_reply.png | Bin .../{en => }/message-board/img/post_index.png | Bin .../message-board/img/request-cycle.jpg | Bin .../{en => }/message-board/img/show_post.png | Bin .../message-board/img/show_replies.png | Bin .../message-board/img/static_home_page.png | Bin .../inline_replying_on_a_post.step | 0 .../message-board/install_devise.step | 0 .../make_a_posts_index_page.step | 0 .../make_it_pretty_with_bootstrap.step | 0 .../{en => }/message-board/message-board.step | 0 sites/{en => }/message-board/mvc_overview.md | 0 .../message-board/the_request_cycle.md | 0 sites/{en => }/ruby/arrays.step | 0 sites/{en => }/ruby/booleans.step | 0 sites/{en => }/ruby/classes.step | 0 sites/{en => }/ruby/command_line.step | 0 sites/{en => }/ruby/conditionals.step | 0 sites/{en => }/ruby/datatypes.step | 0 sites/{en => }/ruby/functions.step | 0 sites/{en => }/ruby/hashes.step | 0 .../{en => }/ruby/how_to_write_a_program.step | 0 sites/{en => }/ruby/input_and_output.step | 0 sites/{en => }/ruby/irb.step | 0 sites/{en => }/ruby/loops.step | 0 sites/{en => }/ruby/nil.step | 0 .../{en => }/ruby/numbers_and_arithmetic.step | 0 .../ruby/overview:_building_blocks.step | 0 sites/{en => }/ruby/overview:_organizing.step | 0 sites/{en => }/ruby/ruby.step | 0 .../ruby/running_programs_from_a_file.step | 0 sites/{en => }/ruby/strings.step | 0 sites/{en => }/ruby/summary:_basics.step | 0 sites/{en => }/ruby/summary:_tools.step | 0 sites/{en => }/ruby/symbols.step | 0 .../{en => }/ruby/using_virtual_machines.step | 0 sites/{en => }/ruby/variables.step | 0 sites/{en => }/ruby/what_is_ruby.step | 0 .../ruby/working_with_collections.step | 0 .../additional_concepts.step | 0 .../final_challenge.step | 0 .../img/rails-test-types.png | Bin .../testing-rails-applications.step | 0 .../testing_frameworks.step | 0 .../types_of_tests.step | 0 .../what_are_tests.step | 0 sites/{en => }/workshop/activities.md | 0 sites/{en => }/workshop/beginners.mw | 0 sites/{en => }/workshop/closing.deck.md | 0 sites/{en => }/workshop/command_prompt.mw | 0 sites/{en => }/workshop/diagrams.mw | 0 .../workshop/foundational_skills.deck.md | 0 sites/{en => }/workshop/helpful_examples.mw | 0 .../workshop/img/Win7_search_programs.jpg | Bin sites/{en => }/workshop/img/acrobat.jpg | Bin sites/{en => }/workshop/img/agile.jpg | Bin sites/{en => }/workshop/img/cheatsheet.png | Bin sites/{en => }/workshop/img/ey_logo_rgb.png | Bin sites/{en => }/workshop/img/firefox.png | Bin sites/{en => }/workshop/img/git.png | Bin sites/{en => }/workshop/img/git_bash.png | Bin sites/{en => }/workshop/img/itunes.png | Bin sites/{en => }/workshop/img/linux_logo.gif | Bin .../{en => }/workshop/img/mac_terminal_sm.png | Bin sites/{en => }/workshop/img/os_x_logo.jpg | Bin sites/{en => }/workshop/img/rails_logo.jpg | Bin .../workshop/img/railsbridge_logo.png | Bin sites/{en => }/workshop/img/ruby-logo.jpg | Bin sites/{en => }/workshop/img/rubygems.png | Bin sites/{en => }/workshop/img/windows_logo.gif | Bin sites/{en => }/workshop/img/wordpress.jpg | Bin .../workshop/more_teacher_training.deck.md | 0 .../more_teacher_training_2016.deck.md | 0 sites/{en => }/workshop/noobie-outline.txt | 0 sites/{en => }/workshop/resources.md | 0 .../workshop/ruby_for_beginners.deck.md | 0 .../workshop/ruby_for_programmers.deck.md | 0 sites/{en => }/workshop/ta_cheat_sheet.md | 0 .../{en => }/workshop/teacher_cheat_sheet.md | 0 sites/{en => }/workshop/teaching_tips.md | 0 sites/{en => }/workshop/topics.md | 0 sites/{en => }/workshop/web_apps.deck.md | 0 sites/{en => }/workshop/welcome.deck.md | 0 sites/{en => }/workshop/workshop.md | 0 sites/zh-tw/nihao/nihao.step | 1 - spec/site_spec.rb | 8 +- 375 files changed, 200 insertions(+), 155 deletions(-) delete mode 100644 locales/en.yml create mode 100644 locales/en/captions.yml create mode 100644 locales/en/general.yml create mode 100644 locales/en/header_sections.yml create mode 100644 locales/en/sites.yml create mode 100644 locales/es/captions.yml create mode 100644 locales/es/general.yml create mode 100644 locales/es/header_sections.yml create mode 100644 locales/es/sites.yml create mode 100644 locales/zh-tw/captions.yml create mode 100644 locales/zh-tw/general.yml create mode 100644 locales/zh-tw/header_section.yml rename sites/{en => }/docs/docs.step (100%) delete mode 100644 sites/es/hola/hola.step rename sites/{en => }/frontend/HTML_attributes.step (100%) rename sites/{en => }/frontend/HTML_structure.step (100%) rename sites/{en => }/frontend/HTML_tags.step (100%) rename sites/{en => }/frontend/_consider_deploying_to_github.step (100%) rename sites/{en => }/frontend/_consider_deploying_to_github_again.step (100%) rename sites/{en => }/frontend/_developer_tools.step (100%) rename sites/{en => }/frontend/_working_effectively_and_efficiently.md (100%) rename sites/{en => }/frontend/add_more_elements.step (100%) rename sites/{en => }/frontend/add_starter_files.step (100%) rename sites/{en => }/frontend/basic_CSS.step (100%) rename sites/{en => }/frontend/basic_javascript.step (100%) rename sites/{en => }/frontend/deploying_to_github.step (100%) rename sites/{en => }/frontend/deploying_to_github_again.step (100%) rename sites/{en => }/frontend/developer_tools.step (100%) rename sites/{en => }/frontend/front-end-lesson.zip-manifest (100%) rename sites/{en => }/frontend/frontend.step (100%) rename sites/{en => }/frontend/get_a_sticker.step (100%) rename sites/{en => }/frontend/grid.html (100%) rename sites/{en => }/frontend/griding_with_bootstrap.step (100%) rename sites/{en => }/frontend/html_quick_reference.md (100%) rename sites/{en => }/frontend/img/boxmodel.png (100%) rename sites/{en => }/frontend/img/css.png (100%) rename sites/{en => }/frontend/img/css_bundler.png (100%) rename sites/{en => }/frontend/img/css_class.png (100%) rename sites/{en => }/frontend/img/css_id.png (100%) rename sites/{en => }/frontend/img/css_zen.png (100%) rename sites/{en => }/frontend/img/devtools.png (100%) rename sites/{en => }/frontend/img/devtools_console.png (100%) rename sites/{en => }/frontend/img/devtools_elements.png (100%) rename sites/{en => }/frontend/img/devtools_network.png (100%) rename sites/{en => }/frontend/img/devtools_script.png (100%) rename sites/{en => }/frontend/img/get_a_sticker_fork_button.png (100%) rename sites/{en => }/frontend/img/get_a_sticker_https.png (100%) rename sites/{en => }/frontend/img/get_a_sticker_output.png (100%) rename sites/{en => }/frontend/img/github_create_repo.png (100%) rename sites/{en => }/frontend/img/github_name_your_repo.png (100%) rename sites/{en => }/frontend/img/hello_html.png (100%) rename sites/{en => }/frontend/img/hello_omg.png (100%) rename sites/{en => }/frontend/img/hello_structure.png (100%) rename sites/{en => }/frontend/img/hello_style.png (100%) rename sites/{en => }/frontend/img/hello_title.png (100%) rename sites/{en => }/frontend/img/hello_world.png (100%) rename sites/{en => }/frontend/img/hello_world_2line.png (100%) rename sites/{en => }/frontend/img/hello_world_2line2.png (100%) rename sites/{en => }/frontend/img/hello_world_jazzy.png (100%) rename sites/{en => }/frontend/img/html_tags_list.png (100%) rename sites/{en => }/frontend/img/jquery_result.png (100%) rename sites/{en => }/frontend/img/page.png (100%) rename sites/{en => }/frontend/img/page_anchors.png (100%) rename sites/{en => }/frontend/img/page_html.png (100%) rename sites/{en => }/frontend/img/page_img.png (100%) rename sites/{en => }/frontend/img/page_sample.jpg (100%) rename sites/{en => }/frontend/img/prompt.png (100%) rename sites/{en => }/frontend/img/zip.png (100%) rename sites/{en => }/frontend/introduction_to_html.step (100%) rename sites/{en => }/frontend/jquery.step (100%) rename sites/{en => }/frontend/jquery_vs_javascript.step (100%) rename sites/{en => }/frontend/make_a_web_page.step (100%) rename sites/{en => }/frontend/make_columns.step (100%) rename sites/{en => }/frontend/resources.step (100%) rename sites/{en => }/frontend/tool_installation.step (100%) rename sites/{en => }/frontend/zip_content/.gitignore (100%) rename sites/{en => }/frontend/zip_content/index.html (100%) rename sites/{en => }/frontend/zip_content/resources/javascript.js (100%) rename sites/{en => }/frontend/zip_content/resources/layout.css (100%) rename sites/{en => }/frontend/zip_content/resources/picture.jpg (100%) rename sites/{en => }/installfest/_command-line-glossary.md (100%) rename sites/{en => }/installfest/_general-glossary.md (100%) rename sites/{en => }/installfest/_install_atom_for_mac.step (100%) rename sites/{en => }/installfest/_install_homebrew.step (100%) rename sites/{en => }/installfest/_install_ruby.step (100%) rename sites/{en => }/installfest/_install_rvm.step (100%) rename sites/{en => }/installfest/_install_textmate.step (100%) rename sites/{en => }/installfest/_ruby-and-rails-glossary.md (100%) rename sites/{en => }/installfest/_switch_to_home_directory.step (100%) rename sites/{en => }/installfest/choose_your_operating_system.step (100%) rename sites/{en => }/installfest/clean_up.step (100%) rename sites/{en => }/installfest/configure_git.step (100%) rename sites/{en => }/installfest/create_a_github_account.step (100%) rename sites/{en => }/installfest/create_a_heroku_account.step (100%) rename sites/{en => }/installfest/create_a_rails_app.step (100%) rename sites/{en => }/installfest/create_an_ssh_key.step (100%) rename sites/{en => }/installfest/deploy_a_rails_app.step (100%) rename sites/{en => }/installfest/editors.step (100%) rename sites/{en => }/installfest/get_a_sticker.step (100%) rename sites/{en => }/installfest/glossary.step (100%) rename sites/{en => }/installfest/img/AboutThisMac.png (100%) rename sites/{en => }/installfest/img/WinRailsInstaller.jpg (100%) rename sites/{en => }/installfest/img/appstore.jpg (100%) rename sites/{en => }/installfest/img/directory.png (100%) rename sites/{en => }/installfest/img/get_a_sticker_you_should_see.png (100%) rename sites/{en => }/installfest/img/install_atom_mac.gif (100%) rename sites/{en => }/installfest/img/railsbridge_ubuntu12-checkbox.png (100%) rename sites/{en => }/installfest/img/railsbridge_windowsScreenshot-commandprompt-pinnedtotaskbar.png (100%) rename sites/{en => }/installfest/img/railsbridge_windowsScreenshot-commandprompt_ror.png (100%) rename sites/{en => }/installfest/img/railsbridge_windows_findingCommandPrompt_win7.png (100%) rename sites/{en => }/installfest/img/railsbridge_windows_findingCommandPrompt_win8.png (100%) rename sites/{en => }/installfest/img/successful_rails_install.png (100%) rename sites/{en => }/installfest/img/xcode-prefs.jpg (100%) rename sites/{en => }/installfest/img/xcode-tools-install.png (100%) rename sites/{en => }/installfest/install_xcode.step (100%) rename sites/{en => }/installfest/install_xcode_command_line_tools.step (100%) rename sites/{en => }/installfest/install_xcode_from_app_store.step (100%) rename sites/{en => }/installfest/install_xcode_from_dvd.step (100%) rename sites/{en => }/installfest/installfest.step (100%) rename sites/{en => }/installfest/linux.step (100%) rename sites/{en => }/installfest/macOS.step (100%) rename sites/{en => }/installfest/osx_rvm.step (100%) rename sites/{en => }/installfest/windows.step (100%) rename sites/{en => }/intro-to-rails/CRUD_with_scaffolding.step (100%) rename sites/{en => }/intro-to-rails/_consider_deploying.step (100%) rename sites/{en => }/intro-to-rails/_consider_deploying_again.step (100%) rename sites/{en => }/intro-to-rails/_deploying_to_heroku.step (100%) rename sites/{en => }/intro-to-rails/_deploying_to_heroku_again.step (100%) rename sites/{en => }/intro-to-rails/_switch_to_home_directory.step (100%) rename sites/{en => }/intro-to-rails/_working_effectively_and_efficiently.md (100%) rename sites/{en => }/intro-to-rails/add_the_project_to_a_git_repo.step (100%) rename sites/{en => }/intro-to-rails/allow_people_to_vote.step (100%) rename sites/{en => }/intro-to-rails/clean_up_links_on_the_topics_list.step (100%) rename sites/{en => }/intro-to-rails/creating_a_migration.step (100%) rename sites/{en => }/intro-to-rails/credits_and_next_steps.step (100%) rename sites/{en => }/intro-to-rails/deploying_to_heroku.step (100%) rename sites/{en => }/intro-to-rails/deploying_to_heroku_again.step (100%) rename sites/{en => }/intro-to-rails/getting_started.step (100%) rename sites/{en => }/intro-to-rails/glossary.step (100%) rename sites/{en => }/intro-to-rails/hooking_up_votes_and_topics.step (100%) rename sites/{en => }/intro-to-rails/img/Seattle_list_with_topic.png (100%) rename sites/{en => }/intro-to-rails/img/Seattle_topic_created.png (100%) rename sites/{en => }/intro-to-rails/img/Seattle_topic_list_page.png (100%) rename sites/{en => }/intro-to-rails/img/Start_page.png (100%) rename sites/{en => }/intro-to-rails/img/atom_add_folder_to_project.png (100%) rename sites/{en => }/intro-to-rails/img/atom_project_as_folder.png (100%) rename sites/{en => }/intro-to-rails/img/finished_app.png (100%) rename sites/{en => }/intro-to-rails/img/mvc.png (100%) rename sites/{en => }/intro-to-rails/img/rails4_rails_info_routing.png (100%) rename sites/{en => }/intro-to-rails/img/workflow.png (100%) rename sites/{en => }/intro-to-rails/intro-to-rails.step (100%) rename sites/{en => }/intro-to-rails/make_the_topic_title_a_link.step (100%) rename sites/{en => }/intro-to-rails/rails_architecture.step (100%) rename sites/{en => }/intro-to-rails/redirect_to_the_topics_list_after_creating_a_new_topic.step (100%) rename sites/{en => }/intro-to-rails/ruby_language.step (100%) rename sites/{en => }/intro-to-rails/running_your_application_locally.step (100%) rename sites/{en => }/intro-to-rails/setting_the_default_page.step (100%) rename sites/{en => }/intro-to-rails/voting_on_topics.step (100%) rename sites/{en => }/javascript-snake-game/img/browser_console.png (100%) rename sites/{en => }/javascript-snake-game/javascript-snake-game.step (100%) rename sites/{en => }/javascript-snake-game/js-snake-game-tutorial.zip-manifest (100%) rename sites/{en => }/javascript-snake-game/js/chunk.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-10.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-11.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-12.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-13.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-2.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-3.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-4.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-5.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-6.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-7.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-8.js (100%) rename sites/{en => }/javascript-snake-game/js/lesson-9.js (100%) rename sites/{en => }/javascript-snake-game/js/snake.js (100%) rename sites/{en => }/javascript-snake-game/lesson-1.step (100%) rename sites/{en => }/javascript-snake-game/lesson-10.step (100%) rename sites/{en => }/javascript-snake-game/lesson-11.step (100%) rename sites/{en => }/javascript-snake-game/lesson-12.step (100%) rename sites/{en => }/javascript-snake-game/lesson-13.step (100%) rename sites/{en => }/javascript-snake-game/lesson-14.step (100%) rename sites/{en => }/javascript-snake-game/lesson-2.step (100%) rename sites/{en => }/javascript-snake-game/lesson-3.step (100%) rename sites/{en => }/javascript-snake-game/lesson-4.step (100%) rename sites/{en => }/javascript-snake-game/lesson-5.step (100%) rename sites/{en => }/javascript-snake-game/lesson-6.step (100%) rename sites/{en => }/javascript-snake-game/lesson-7.step (100%) rename sites/{en => }/javascript-snake-game/lesson-8.step (100%) rename sites/{en => }/javascript-snake-game/lesson-9.step (100%) rename sites/{en => }/javascript-snake-game/zip_content/index.html (100%) rename sites/{en => }/javascript-snake-game/zip_content/snake.js (100%) rename sites/{en => }/javascript-to-do-list-with-react/AdvancedTodoList.zip-manifest (100%) rename sites/{en => }/javascript-to-do-list-with-react/adding_an_item.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/building_complex_applications_with_react.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/creating_a_list.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/deploying_your_site.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/developer_tools.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/javascript-to-do-list-with-react.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/loading_items.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/marking_an_item_as_complete.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/next_steps.step (100%) rename sites/{en => }/javascript-to-do-list-with-react/zip_content/app.js (100%) rename sites/{en => }/javascript-to-do-list-with-react/zip_content/console-polyfill.js (100%) rename sites/{en => }/javascript-to-do-list-with-react/zip_content/debut_light.png (100%) rename sites/{en => }/javascript-to-do-list-with-react/zip_content/index.html (100%) rename sites/{en => }/javascript-to-do-list-with-react/zip_content/store.js (100%) rename sites/{en => }/javascript-to-do-list-with-react/zip_content/styles.css (100%) rename sites/{en => }/javascript-to-do-list/IntermediateTodoList.zip-manifest (100%) rename sites/{en => }/javascript-to-do-list/_deploying_your_site.md (100%) rename sites/{en => }/javascript-to-do-list/_lesson_format.md (100%) rename sites/{en => }/javascript-to-do-list/_teachers_note.md (100%) rename sites/{en => }/javascript-to-do-list/adding_an_item.step (100%) rename sites/{en => }/javascript-to-do-list/creating_a_list.step (100%) rename sites/{en => }/javascript-to-do-list/deploying_your_site.step (100%) rename sites/{en => }/javascript-to-do-list/developer_tools.step (100%) rename sites/{en => }/javascript-to-do-list/img/browser_console.png (100%) rename sites/{en => }/javascript-to-do-list/img/finished_app.png (100%) rename sites/{en => }/javascript-to-do-list/img/network_tab.png (100%) rename sites/{en => }/javascript-to-do-list/img/text_editor_html.png (100%) rename sites/{en => }/javascript-to-do-list/javascript-to-do-list.step (100%) rename sites/{en => }/javascript-to-do-list/loading_items.step (100%) rename sites/{en => }/javascript-to-do-list/marking_an_item_as_complete.step (100%) rename sites/{en => }/javascript-to-do-list/next_steps.step (100%) rename sites/{en => }/javascript-to-do-list/playing_with_jquery.step (100%) rename sites/{en => }/javascript-to-do-list/programming_with_javascript.step (100%) rename sites/{en => }/javascript-to-do-list/the_basics_of_a_website.step (100%) rename sites/{en => }/javascript-to-do-list/zip_content/app.js (100%) rename sites/{en => }/javascript-to-do-list/zip_content/debut_light.png (100%) rename sites/{en => }/javascript-to-do-list/zip_content/index.html (100%) rename sites/{en => }/javascript-to-do-list/zip_content/styles.css (100%) rename sites/{en => }/job-board/add_a_navbar.step (100%) rename sites/{en => }/job-board/add_a_new_job_form.step (100%) rename sites/{en => }/job-board/add_more_things.step (100%) rename sites/{en => }/job-board/create_a_rails_app.step (100%) rename sites/{en => }/job-board/crud_and_resourceful_routing.step (100%) rename sites/{en => }/job-board/delete_job_listings.step (100%) rename sites/{en => }/job-board/img/crud_grid.jpg (100%) rename sites/{en => }/job-board/img/crud_rails_methods.jpg (100%) rename sites/{en => }/job-board/img/rails-routes.png (100%) rename sites/{en => }/job-board/img/request-cycle.jpg (100%) rename sites/{en => }/job-board/job-board.step (100%) rename sites/{en => }/job-board/listing_the_jobs.step (100%) rename sites/{en => }/job-board/make_a_jobs_home_page.step (100%) rename sites/{en => }/job-board/make_the_form_work.step (100%) rename sites/{en => }/job-board/store_jobs_in_the_database.step (100%) rename sites/{en => }/job-board/the_request_cycle.step (100%) rename sites/{en => }/job-board/update_job_listings.step (100%) rename sites/{en => }/learn-to-code/argv.md (100%) rename sites/{en => }/learn-to-code/arrays.md (100%) rename sites/{en => }/learn-to-code/computers.md (100%) rename sites/{en => }/learn-to-code/extra.md (100%) rename sites/{en => }/learn-to-code/functions.md (100%) rename sites/{en => }/learn-to-code/hashes.md (100%) rename sites/{en => }/learn-to-code/img/cookie-recipe.gif (100%) rename sites/{en => }/learn-to-code/img/dot.jpg (100%) rename sites/{en => }/learn-to-code/img/fruit-banana-snack-banana.svg (100%) rename sites/{en => }/learn-to-code/img/one-infinite-loop.jpg (100%) rename sites/{en => }/learn-to-code/img/snack-apple.svg (100%) rename sites/{en => }/learn-to-code/img/snack-fruit.svg (100%) rename sites/{en => }/learn-to-code/img/spoon.jpg (100%) rename sites/{en => }/learn-to-code/img/truthiness.png (100%) rename sites/{en => }/learn-to-code/img/warehouse.jpg (100%) rename sites/{en => }/learn-to-code/img/wargames-terminal.jpg (100%) rename sites/{en => }/learn-to-code/input_and_output.md (100%) rename sites/{en => }/learn-to-code/learn-to-code.md (100%) rename sites/{en => }/learn-to-code/logic.md (100%) rename sites/{en => }/learn-to-code/loops.md (100%) rename sites/{en => }/learn-to-code/methods.md (100%) rename sites/{en => }/learn-to-code/next_steps.md (100%) rename sites/{en => }/learn-to-code/nil.md (100%) rename sites/{en => }/learn-to-code/numbers.md (100%) rename sites/{en => }/learn-to-code/objects.md (100%) rename sites/{en => }/learn-to-code/sinatra.md (100%) rename sites/{en => }/learn-to-code/strings.md (100%) rename sites/{en => }/learn-to-code/the_command_line.md (100%) rename sites/{en => }/learn-to-code/todo-learntocode.md (100%) rename sites/{en => }/learn-to-code/variables.md (100%) rename sites/{en => }/message-board/add_other_features_of_your_choosing.step (100%) rename sites/{en => }/message-board/add_pages_to_create_and_look_at_individual_posts.step (100%) rename sites/{en => }/message-board/add_replying.step (100%) rename sites/{en => }/message-board/commands.md (100%) rename sites/{en => }/message-board/create_a_new_rails_app_with_a_static_home_page.step (100%) rename sites/{en => }/message-board/creating_a_new_controller.md (100%) rename sites/{en => }/message-board/img/create_post.png (100%) rename sites/{en => }/message-board/img/create_reply.png (100%) rename sites/{en => }/message-board/img/header.png (100%) rename sites/{en => }/message-board/img/inline_reply.png (100%) rename sites/{en => }/message-board/img/post_index.png (100%) rename sites/{en => }/message-board/img/request-cycle.jpg (100%) rename sites/{en => }/message-board/img/show_post.png (100%) rename sites/{en => }/message-board/img/show_replies.png (100%) rename sites/{en => }/message-board/img/static_home_page.png (100%) rename sites/{en => }/message-board/inline_replying_on_a_post.step (100%) rename sites/{en => }/message-board/install_devise.step (100%) rename sites/{en => }/message-board/make_a_posts_index_page.step (100%) rename sites/{en => }/message-board/make_it_pretty_with_bootstrap.step (100%) rename sites/{en => }/message-board/message-board.step (100%) rename sites/{en => }/message-board/mvc_overview.md (100%) rename sites/{en => }/message-board/the_request_cycle.md (100%) rename sites/{en => }/ruby/arrays.step (100%) rename sites/{en => }/ruby/booleans.step (100%) rename sites/{en => }/ruby/classes.step (100%) rename sites/{en => }/ruby/command_line.step (100%) rename sites/{en => }/ruby/conditionals.step (100%) rename sites/{en => }/ruby/datatypes.step (100%) rename sites/{en => }/ruby/functions.step (100%) rename sites/{en => }/ruby/hashes.step (100%) rename sites/{en => }/ruby/how_to_write_a_program.step (100%) rename sites/{en => }/ruby/input_and_output.step (100%) rename sites/{en => }/ruby/irb.step (100%) rename sites/{en => }/ruby/loops.step (100%) rename sites/{en => }/ruby/nil.step (100%) rename sites/{en => }/ruby/numbers_and_arithmetic.step (100%) rename sites/{en => }/ruby/overview:_building_blocks.step (100%) rename sites/{en => }/ruby/overview:_organizing.step (100%) rename sites/{en => }/ruby/ruby.step (100%) rename sites/{en => }/ruby/running_programs_from_a_file.step (100%) rename sites/{en => }/ruby/strings.step (100%) rename sites/{en => }/ruby/summary:_basics.step (100%) rename sites/{en => }/ruby/summary:_tools.step (100%) rename sites/{en => }/ruby/symbols.step (100%) rename sites/{en => }/ruby/using_virtual_machines.step (100%) rename sites/{en => }/ruby/variables.step (100%) rename sites/{en => }/ruby/what_is_ruby.step (100%) rename sites/{en => }/ruby/working_with_collections.step (100%) rename sites/{en => }/testing-rails-applications/additional_concepts.step (100%) rename sites/{en => }/testing-rails-applications/final_challenge.step (100%) rename sites/{en => }/testing-rails-applications/img/rails-test-types.png (100%) rename sites/{en => }/testing-rails-applications/testing-rails-applications.step (100%) rename sites/{en => }/testing-rails-applications/testing_frameworks.step (100%) rename sites/{en => }/testing-rails-applications/types_of_tests.step (100%) rename sites/{en => }/testing-rails-applications/what_are_tests.step (100%) rename sites/{en => }/workshop/activities.md (100%) rename sites/{en => }/workshop/beginners.mw (100%) rename sites/{en => }/workshop/closing.deck.md (100%) rename sites/{en => }/workshop/command_prompt.mw (100%) rename sites/{en => }/workshop/diagrams.mw (100%) rename sites/{en => }/workshop/foundational_skills.deck.md (100%) rename sites/{en => }/workshop/helpful_examples.mw (100%) rename sites/{en => }/workshop/img/Win7_search_programs.jpg (100%) rename sites/{en => }/workshop/img/acrobat.jpg (100%) rename sites/{en => }/workshop/img/agile.jpg (100%) rename sites/{en => }/workshop/img/cheatsheet.png (100%) rename sites/{en => }/workshop/img/ey_logo_rgb.png (100%) rename sites/{en => }/workshop/img/firefox.png (100%) rename sites/{en => }/workshop/img/git.png (100%) rename sites/{en => }/workshop/img/git_bash.png (100%) rename sites/{en => }/workshop/img/itunes.png (100%) rename sites/{en => }/workshop/img/linux_logo.gif (100%) rename sites/{en => }/workshop/img/mac_terminal_sm.png (100%) rename sites/{en => }/workshop/img/os_x_logo.jpg (100%) rename sites/{en => }/workshop/img/rails_logo.jpg (100%) rename sites/{en => }/workshop/img/railsbridge_logo.png (100%) rename sites/{en => }/workshop/img/ruby-logo.jpg (100%) rename sites/{en => }/workshop/img/rubygems.png (100%) rename sites/{en => }/workshop/img/windows_logo.gif (100%) rename sites/{en => }/workshop/img/wordpress.jpg (100%) rename sites/{en => }/workshop/more_teacher_training.deck.md (100%) rename sites/{en => }/workshop/more_teacher_training_2016.deck.md (100%) rename sites/{en => }/workshop/noobie-outline.txt (100%) rename sites/{en => }/workshop/resources.md (100%) rename sites/{en => }/workshop/ruby_for_beginners.deck.md (100%) rename sites/{en => }/workshop/ruby_for_programmers.deck.md (100%) rename sites/{en => }/workshop/ta_cheat_sheet.md (100%) rename sites/{en => }/workshop/teacher_cheat_sheet.md (100%) rename sites/{en => }/workshop/teaching_tips.md (100%) rename sites/{en => }/workshop/topics.md (100%) rename sites/{en => }/workshop/web_apps.deck.md (100%) rename sites/{en => }/workshop/welcome.deck.md (100%) rename sites/{en => }/workshop/workshop.md (100%) delete mode 100644 sites/zh-tw/nihao/nihao.step diff --git a/app.rb b/app.rb index fdb12c9dc..bce4ace91 100755 --- a/app.rb +++ b/app.rb @@ -9,45 +9,42 @@ require 'zip' require 'tmpdir' -here = File.expand_path File.dirname(__FILE__) +here = __dir__ lib = File.expand_path "#{here}/lib" $: << lib -require "doc_page" -require "step_page" -require "markdown_page" -require "media_wiki_page" -require "raw_page" -require "deck" -require "deck/rack_app" -require "titleizer" -require "site" +require 'doc_page' +require 'step_page' +require 'markdown_page' +require 'media_wiki_page' +require 'raw_page' +require 'deck' +require 'deck/rack_app' +require 'titleizer' +require 'site' require 'sprockets' require 'jquery-cdn' -class InstallFest < Sinatra::Application # todo: use Sinatra::Base instead, with more explicit config +class InstallFest < Sinatra::Application + # TODO: use Sinatra::Base instead, with more explicit config include Erector::Mixin - DEFAULT_SITES = {en: "docs", es: "hola", :"zh-tw" => "nihao" } - # Set available locales in Array of Strings; this is also used when # checking availability in dynamic locale assignment, they must be strings. - AVAILABLE_LOCALES = DEFAULT_SITES.keys.map(&:to_s) + AVAILABLE_LOCALES = %i[en es zh-tw].freeze set :assets, Sprockets::Environment.new - settings.assets.append_path "assets/stylesheets" - settings.assets.append_path "assets/javascripts" - settings.assets.append_path "public/fonts" + settings.assets.append_path 'assets/stylesheets' + settings.assets.append_path 'assets/javascripts' + settings.assets.append_path 'public/fonts' settings.assets.append_path Bootstrap.javascripts_path JqueryCdn.install(settings.assets) - if settings.environment == :development - set :cookie_options, domain: nil - end + set :cookie_options, domain: nil if settings.environment == :development configure do I18n::Backend::Simple.include(I18n::Backend::Fallbacks) - I18n.load_path = Dir[File.join(settings.root, 'locales', '*.yml')] + I18n.load_path = Dir[File.join(settings.root, 'locales', '**/*.yml')] I18n.backend.load_translations I18n.available_locales = AVAILABLE_LOCALES @@ -57,28 +54,28 @@ class InstallFest < Sinatra::Application # todo: use Sinatra::Base instead, wi def initialize super - @here = File.expand_path(File.dirname(__FILE__)) + @here = __dir__ end attr_reader :here attr_writer :default_site - # todo: test + # TODO: test # returns the most-specific hostname component, e.g. "foo" for "foo.example.com" def subdomain - host.split(".").first + host.split('.').first end def default_site if host && sites.include?(site = subdomain) site else - DEFAULT_SITES[I18n.locale.to_sym] # no symbol DoS because it's whitelisted + 'docs' end end def host - request && request.host + request&.host end def site_dir @@ -86,7 +83,7 @@ def site_dir end def sites_dir - Site.sites_dir(I18n.locale) + Site.sites_dir end def sites @@ -107,24 +104,20 @@ def redirect_pages end before do - begin - I18n.locale = dynamic_locale - rescue I18n::InvalidLocale - I18n.locale = I18n.default_locale - end + I18n.locale = dynamic_locale + rescue I18n::InvalidLocale + I18n.locale = I18n.default_locale end after '/:site/*' do # Any real page (starts with a site and doesn't end with an extension) # gets saved as the 'back' for the next pageload. - if sites.include?(params[:site]) && !request.fullpath.match(/\..+\z/) - cookies[:docs_back_path] = request.fullpath - end + cookies[:docs_back_path] = request.fullpath if sites.include?(params[:site]) && !request.fullpath.match(/\..+\z/) end def dynamic_locale - (params && (params[:locale] or params[:l])) or - (host && AVAILABLE_LOCALES.include?(subdomain) && subdomain) or + (params && (params[:locale] || params[:l])) || + (host && AVAILABLE_LOCALES.include?(subdomain) && subdomain) || (ENV['SITE_LOCALE']) end @@ -133,7 +126,7 @@ def src end def ext - $1 if doc_path.match(/\.(.*)/) + Regexp.last_match(1) if doc_path.match(/\.(.*)/) end def doc_path @@ -162,48 +155,46 @@ def back_path end def render_page - begin - options = { - site: Site.named(params[:site], I18n.locale), - page_name: params[:name], - doc_title: Titleizer.title_for_page(params[:name]), - doc_path: doc_path, - back: back_path, - src: src, - locale: I18n.locale, - } + options = { + site: Site.named(params[:site]), + page_name: params[:name], + doc_title: Titleizer.title_for_page(params[:name]), + doc_path: doc_path, + back: back_path, + src: src, + locale: I18n.locale + } - case ext + case ext - when "deck.md", "deck" - render_deck + when 'deck.md', 'deck' + render_deck - when "md" - MarkdownPage.new(options).to_html + when 'md' + MarkdownPage.new(options).to_html - when "mw" - MediaWikiPage.new(options).to_html + when 'mw' + MediaWikiPage.new(options).to_html - when "step" - StepPage.new(options).to_html + when 'step' + StepPage.new(options).to_html - else - raise "unknown file type #{doc_path}" - end + else + raise "unknown file type #{doc_path}" + end + rescue Errno::ENOENT => e + p e + e.backtrace.each do |line| + break if line =~ %r{sinatra/base.rb} - rescue Errno::ENOENT => e - p e - e.backtrace.each do |line| - break if line =~ /sinatra\/base.rb/ - puts "\t"+line - end - halt 404 + puts "\t" + line end + halt 404 end def render_deck slides = Deck::Slide.split(src) - Deck::SlideDeck.new(:slides => slides).to_pretty + Deck::SlideDeck.new(slides: slides).to_pretty end before do @@ -214,7 +205,7 @@ def render_deck halt 404 end - get "/assets/:file.:ext" do + get '/assets/:file.:ext' do mime_type = { 'js' => 'application/javascript', 'css' => 'text/css', @@ -230,29 +221,27 @@ def render_deck send_file font_path end - get "/" do + get '/' do redirect "/#{default_site}/" end - get "/:site/:name/src" do - begin - RawPage.new( - site: Site.named(params[:site], I18n.locale), - page_name: params[:name], - doc_title: File.basename(doc_path), - doc_path: doc_path, - src: src, - locale: I18n.locale, - ).to_html - rescue Errno::ENOENT => e - p e - halt 404 - end + get '/:site/:name/src' do + RawPage.new( + site: Site.named(params[:site], I18n.locale), + page_name: params[:name], + doc_title: File.basename(doc_path), + doc_path: doc_path, + src: src, + locale: I18n.locale + ).to_html + rescue Errno::ENOENT => e + p e + halt 404 end - get "/:site/:name.zip" do + get '/:site/:name.zip' do manifest_path = "#{site_dir}/#{params[:name]}.zip-manifest" - if File.exists?(manifest_path) + if File.exist?(manifest_path) manifest_files = File.read(manifest_path).split("\n") zip_path = File.join(Dir.tmpdir, "#{params[:name]}.zip") FileUtils.rm_rf(zip_path) @@ -268,9 +257,9 @@ def render_deck end end - get "/:site/:name.:ext" do + get '/:site/:name.:ext' do if sites.include?(params[:site]) - if params[:ext] == "deck" # to show a markdown page as slides, change the ".md" to ".deck" + if params[:ext] == 'deck' # to show a markdown page as slides, change the ".md" to ".deck" render_deck else send_file "#{site_dir}/#{params[:name]}.#{params[:ext]}" @@ -278,18 +267,16 @@ def render_deck end end - get "/:site/:subdir/:name.:ext" do - if sites.include?(params[:site]) - send_file "#{site_dir}/#{params[:subdir]}/#{params[:name]}.#{params[:ext]}" - end + get '/:site/:subdir/:name.:ext' do + send_file "#{site_dir}/#{params[:subdir]}/#{params[:name]}.#{params[:ext]}" if sites.include?(params[:site]) end - get "/:site/:name/" do + get '/:site/:name/' do # remove any extraneous slash from otherwise well-formed page URLs redirect request.fullpath.chomp('/') end - get "/:site/:name" do + get '/:site/:name' do site_name = params[:site] if redirect_sites[site_name] redirect "#{redirect_sites[site_name]}/#{params[:name]}" @@ -304,22 +291,22 @@ def render_deck end end - get "/:site/:name/:section/" do + get '/:site/:name/:section/' do # remove any extraneous slash from otherwise well-formed page URLs redirect request.fullpath.chomp('/') end - get "/:site/:name/:section" do + get '/:site/:name/:section' do render_page end - get "/:site" do + get '/:site' do # add a slash to any URLs that contain only a site # (otherwise paths in that site's pages would resolve relative to the root) redirect "#{request.fullpath}/" end - get "/:site/" do + get '/:site/' do site_name = params[:site] if redirect_sites[site_name] redirect "#{redirect_sites[site_name]}/" diff --git a/lib/site.rb b/lib/site.rb index b8fc9b583..e40b0fbce 100644 --- a/lib/site.rb +++ b/lib/site.rb @@ -1,27 +1,27 @@ class Site - DOC_TYPES = %w{step md deck.md mw} + DOC_TYPES = %w[step md deck.md mw].freeze - @@here = File.expand_path(File.dirname(__FILE__)) + @@here = __dir__ @@project_root = File.dirname(@@here) - def self.sites_dir locale = "en" - sites_dir = File.join(["sites", locale.to_s].compact) - File.expand_path(sites_dir, @@project_root) + def self.sites_dir + File.expand_path('sites', @@project_root) end - def self.all locale = "en" - Dir[File.join(sites_dir(locale), '*')].map{|dir| Site.new(dir)} + def self.all + Dir[File.join(sites_dir, '*')].map { |dir| Site.new(dir) } end - def self.named name, locale = "en" - site = all(locale).detect { |site| site.name == name } - raise "No site found with the name '#{name}' in locale '#{locale}'" unless site + def self.named(name) + site = all.detect { |folder| folder.name == name } + raise "No site found with the name '#{name}'" unless site + site end attr_reader :dir - def initialize dir + def initialize(dir) @dir = dir end @@ -31,13 +31,13 @@ def name def docs file_path_glob = File.join(@dir, "*.{#{DOC_TYPES.join(',')}}") - Dir[file_path_glob].map{|path| Doc.new(path)} + Dir[file_path_glob].map { |path| Doc.new(path) } end class Doc attr_reader :path - def initialize path + def initialize(path) @path = path end @@ -48,6 +48,5 @@ def filename def name filename.split('.').first end - end end diff --git a/lib/site_index.rb b/lib/site_index.rb index 3aa360eb2..cfca58976 100644 --- a/lib/site_index.rb +++ b/lib/site_index.rb @@ -28,7 +28,7 @@ def categorized_sites def sites return @sites if @sites - @sites = Dir.glob("#{Site.sites_dir(@locale)}/**").map { |filename| File.basename(filename) }.sort + @sites = Dir.glob("#{Site.sites_dir}/**").map { |filename| File.basename(filename) }.sort end def site_category category diff --git a/locales/en.yml b/locales/en.yml deleted file mode 100644 index b00896c93..000000000 --- a/locales/en.yml +++ /dev/null @@ -1,34 +0,0 @@ -en: - captions: - terminal: "Type this in the terminal:" - irb: "Type this in irb:" - result: "Expected result:" - fuzzy_result: "Approximate expected result:" - link: "Go on to" - - general: - type_in_file: "Type this in the file %{filename}:" - further_reading: "Further Reading" - fuzzy_hint: "The greyed-out text may differ and is not important." - step_title: "Step %{num}" - step_title_suffix: ": " - next_step: "Next Step:" - option: "Option %{num}: " - verify: "Verify %{text}" - goals: "Goals" - expand_all: "Expand All" - other_pages: "Other Pages" - back_to: "Back to" - - header_section: - steps: "Steps" - explanation: "Explanation" - overview: "Overview" - discussion: "Discussion Items" - hints: "Hints" - challenge: "Challenge(s)" - tools_and_references: "Tools and References" - requirements: "Requirements to advance" - - sites: - other_categories: Other Stuff \ No newline at end of file diff --git a/locales/en/captions.yml b/locales/en/captions.yml new file mode 100644 index 000000000..4903b86a7 --- /dev/null +++ b/locales/en/captions.yml @@ -0,0 +1,7 @@ +en: + captions: + terminal: "Type this in the terminal:" + irb: "Type this in irb:" + result: "Expected result:" + fuzzy_result: "Approximate expected result:" + link: "Go on to" diff --git a/locales/en/general.yml b/locales/en/general.yml new file mode 100644 index 000000000..71e81ed7f --- /dev/null +++ b/locales/en/general.yml @@ -0,0 +1,14 @@ +en: + general: + type_in_file: "Type this in the file %{filename}:" + further_reading: "Further Reading" + fuzzy_hint: "The greyed-out text may differ and is not important." + step_title: "Step %{num}" + step_title_suffix: ": " + next_step: "Next Step:" + option: "Option %{num}: " + verify: "Verify %{text}" + goals: "Goals" + expand_all: "Expand All" + other_pages: "Other Pages" + back_to: "Back to" diff --git a/locales/en/header_sections.yml b/locales/en/header_sections.yml new file mode 100644 index 000000000..df5b8c68a --- /dev/null +++ b/locales/en/header_sections.yml @@ -0,0 +1,10 @@ +en: + header_section: + steps: "Steps" + explanation: "Explanation" + overview: "Overview" + discussion: "Discussion Items" + hints: "Hints" + challenge: "Challenge(s)" + tools_and_references: "Tools and References" + requirements: "Requirements to advance" diff --git a/locales/en/sites.yml b/locales/en/sites.yml new file mode 100644 index 000000000..906063685 --- /dev/null +++ b/locales/en/sites.yml @@ -0,0 +1,3 @@ +en: + sites: + other_categories: Other Stuff diff --git a/locales/es/captions.yml b/locales/es/captions.yml new file mode 100644 index 000000000..c2e4ea129 --- /dev/null +++ b/locales/es/captions.yml @@ -0,0 +1,7 @@ +es: + captions: + terminal: "Escribe esto en la línea de comandos:" + irb: "Escribe esto en irb:" + result: "Resultado esperado:" + fuzzy_result: "Resultado aproximado esperado:" + link: "Ir a" diff --git a/locales/es/general.yml b/locales/es/general.yml new file mode 100644 index 000000000..116fb0f16 --- /dev/null +++ b/locales/es/general.yml @@ -0,0 +1,14 @@ +es: + general: + type_in_file: "Escribe esto en el archivo %{filename}:" + further_reading: "Lectura adicional" + fuzzy_hint: "El texto en gris puede variar y no es tan importante." + step_title: "Paso %{num}" + step_title_suffix: ": " + next_step: "Próximo paso:" + option: "Opción %{num}: " + verify: "Verifica %{text}" + goals: "Objetivos" + expand_all: "Expandir Todo" + other_pages: "Otras Páginas" + back_to: "Regresar a" diff --git a/locales/es/header_sections.yml b/locales/es/header_sections.yml new file mode 100644 index 000000000..21e082978 --- /dev/null +++ b/locales/es/header_sections.yml @@ -0,0 +1,10 @@ +en: + header_section: + steps: "Pasos" + explanation: "Explicación" + overview: "Resumen" + discussion: "Elementos para discusión" + hints: "Pistas" + challenge: "Reto(s)" + tools_and_references: "Herramientas y Referencias" + requirements: "Requisitos para avanzar" diff --git a/locales/es/sites.yml b/locales/es/sites.yml new file mode 100644 index 000000000..1cdac0ba2 --- /dev/null +++ b/locales/es/sites.yml @@ -0,0 +1,3 @@ +es: + sites: + other_categories: Otras cosas diff --git a/locales/zh-tw/captions.yml b/locales/zh-tw/captions.yml new file mode 100644 index 000000000..a4947bae8 --- /dev/null +++ b/locales/zh-tw/captions.yml @@ -0,0 +1,7 @@ +zh-tw: + captions: + terminal: "在終端機打這些字:" + irb: "在 irb 打這些字:" + result: "預期的結果:" + fuzzy_result: "大概預期的結果:" + link: "來這裡:" diff --git a/locales/zh-tw/general.yml b/locales/zh-tw/general.yml new file mode 100644 index 000000000..e0437e289 --- /dev/null +++ b/locales/zh-tw/general.yml @@ -0,0 +1,14 @@ +zh-tw: + general: + type_in_file: "在 %{filename} 檔裡面打這些字:" + further_reading: "延伸閱讀" + fuzzy_hint: "塗灰的字可能有所不同,不重要。" + goals: "目標" + verify: "檢查 %{text}" + option: "選項 %{num}:" + next_step: "下一步:" + step_title: "步驟 %{num}" + step_title_suffix: ":" + expand_all: "全部展開" + other_pages: "其他頁面" + back_to: "回到" diff --git a/locales/zh-tw/header_section.yml b/locales/zh-tw/header_section.yml new file mode 100644 index 000000000..645c69d33 --- /dev/null +++ b/locales/zh-tw/header_section.yml @@ -0,0 +1,10 @@ +zh-tw: + header_section: + steps: "步驟" + explanation: "解說" + overview: "摘要" + discussion: "討論" + hints: "秘訣" + challenge: "挑戰" + tools_and_references: "工具、參考資料" + requirements: "通關條件" diff --git a/sites/en/docs/docs.step b/sites/docs/docs.step similarity index 100% rename from sites/en/docs/docs.step rename to sites/docs/docs.step diff --git a/sites/es/hola/hola.step b/sites/es/hola/hola.step deleted file mode 100644 index f0e5f45b0..000000000 --- a/sites/es/hola/hola.step +++ /dev/null @@ -1 +0,0 @@ -message "Hola! Que tal?" diff --git a/sites/en/frontend/HTML_attributes.step b/sites/frontend/HTML_attributes.step similarity index 100% rename from sites/en/frontend/HTML_attributes.step rename to sites/frontend/HTML_attributes.step diff --git a/sites/en/frontend/HTML_structure.step b/sites/frontend/HTML_structure.step similarity index 100% rename from sites/en/frontend/HTML_structure.step rename to sites/frontend/HTML_structure.step diff --git a/sites/en/frontend/HTML_tags.step b/sites/frontend/HTML_tags.step similarity index 100% rename from sites/en/frontend/HTML_tags.step rename to sites/frontend/HTML_tags.step diff --git a/sites/en/frontend/_consider_deploying_to_github.step b/sites/frontend/_consider_deploying_to_github.step similarity index 100% rename from sites/en/frontend/_consider_deploying_to_github.step rename to sites/frontend/_consider_deploying_to_github.step diff --git a/sites/en/frontend/_consider_deploying_to_github_again.step b/sites/frontend/_consider_deploying_to_github_again.step similarity index 100% rename from sites/en/frontend/_consider_deploying_to_github_again.step rename to sites/frontend/_consider_deploying_to_github_again.step diff --git a/sites/en/frontend/_developer_tools.step b/sites/frontend/_developer_tools.step similarity index 100% rename from sites/en/frontend/_developer_tools.step rename to sites/frontend/_developer_tools.step diff --git a/sites/en/frontend/_working_effectively_and_efficiently.md b/sites/frontend/_working_effectively_and_efficiently.md similarity index 100% rename from sites/en/frontend/_working_effectively_and_efficiently.md rename to sites/frontend/_working_effectively_and_efficiently.md diff --git a/sites/en/frontend/add_more_elements.step b/sites/frontend/add_more_elements.step similarity index 100% rename from sites/en/frontend/add_more_elements.step rename to sites/frontend/add_more_elements.step diff --git a/sites/en/frontend/add_starter_files.step b/sites/frontend/add_starter_files.step similarity index 100% rename from sites/en/frontend/add_starter_files.step rename to sites/frontend/add_starter_files.step diff --git a/sites/en/frontend/basic_CSS.step b/sites/frontend/basic_CSS.step similarity index 100% rename from sites/en/frontend/basic_CSS.step rename to sites/frontend/basic_CSS.step diff --git a/sites/en/frontend/basic_javascript.step b/sites/frontend/basic_javascript.step similarity index 100% rename from sites/en/frontend/basic_javascript.step rename to sites/frontend/basic_javascript.step diff --git a/sites/en/frontend/deploying_to_github.step b/sites/frontend/deploying_to_github.step similarity index 100% rename from sites/en/frontend/deploying_to_github.step rename to sites/frontend/deploying_to_github.step diff --git a/sites/en/frontend/deploying_to_github_again.step b/sites/frontend/deploying_to_github_again.step similarity index 100% rename from sites/en/frontend/deploying_to_github_again.step rename to sites/frontend/deploying_to_github_again.step diff --git a/sites/en/frontend/developer_tools.step b/sites/frontend/developer_tools.step similarity index 100% rename from sites/en/frontend/developer_tools.step rename to sites/frontend/developer_tools.step diff --git a/sites/en/frontend/front-end-lesson.zip-manifest b/sites/frontend/front-end-lesson.zip-manifest similarity index 100% rename from sites/en/frontend/front-end-lesson.zip-manifest rename to sites/frontend/front-end-lesson.zip-manifest diff --git a/sites/en/frontend/frontend.step b/sites/frontend/frontend.step similarity index 100% rename from sites/en/frontend/frontend.step rename to sites/frontend/frontend.step diff --git a/sites/en/frontend/get_a_sticker.step b/sites/frontend/get_a_sticker.step similarity index 100% rename from sites/en/frontend/get_a_sticker.step rename to sites/frontend/get_a_sticker.step diff --git a/sites/en/frontend/grid.html b/sites/frontend/grid.html similarity index 100% rename from sites/en/frontend/grid.html rename to sites/frontend/grid.html diff --git a/sites/en/frontend/griding_with_bootstrap.step b/sites/frontend/griding_with_bootstrap.step similarity index 100% rename from sites/en/frontend/griding_with_bootstrap.step rename to sites/frontend/griding_with_bootstrap.step diff --git a/sites/en/frontend/html_quick_reference.md b/sites/frontend/html_quick_reference.md similarity index 100% rename from sites/en/frontend/html_quick_reference.md rename to sites/frontend/html_quick_reference.md diff --git a/sites/en/frontend/img/boxmodel.png b/sites/frontend/img/boxmodel.png similarity index 100% rename from sites/en/frontend/img/boxmodel.png rename to sites/frontend/img/boxmodel.png diff --git a/sites/en/frontend/img/css.png b/sites/frontend/img/css.png similarity index 100% rename from sites/en/frontend/img/css.png rename to sites/frontend/img/css.png diff --git a/sites/en/frontend/img/css_bundler.png b/sites/frontend/img/css_bundler.png similarity index 100% rename from sites/en/frontend/img/css_bundler.png rename to sites/frontend/img/css_bundler.png diff --git a/sites/en/frontend/img/css_class.png b/sites/frontend/img/css_class.png similarity index 100% rename from sites/en/frontend/img/css_class.png rename to sites/frontend/img/css_class.png diff --git a/sites/en/frontend/img/css_id.png b/sites/frontend/img/css_id.png similarity index 100% rename from sites/en/frontend/img/css_id.png rename to sites/frontend/img/css_id.png diff --git a/sites/en/frontend/img/css_zen.png b/sites/frontend/img/css_zen.png similarity index 100% rename from sites/en/frontend/img/css_zen.png rename to sites/frontend/img/css_zen.png diff --git a/sites/en/frontend/img/devtools.png b/sites/frontend/img/devtools.png similarity index 100% rename from sites/en/frontend/img/devtools.png rename to sites/frontend/img/devtools.png diff --git a/sites/en/frontend/img/devtools_console.png b/sites/frontend/img/devtools_console.png similarity index 100% rename from sites/en/frontend/img/devtools_console.png rename to sites/frontend/img/devtools_console.png diff --git a/sites/en/frontend/img/devtools_elements.png b/sites/frontend/img/devtools_elements.png similarity index 100% rename from sites/en/frontend/img/devtools_elements.png rename to sites/frontend/img/devtools_elements.png diff --git a/sites/en/frontend/img/devtools_network.png b/sites/frontend/img/devtools_network.png similarity index 100% rename from sites/en/frontend/img/devtools_network.png rename to sites/frontend/img/devtools_network.png diff --git a/sites/en/frontend/img/devtools_script.png b/sites/frontend/img/devtools_script.png similarity index 100% rename from sites/en/frontend/img/devtools_script.png rename to sites/frontend/img/devtools_script.png diff --git a/sites/en/frontend/img/get_a_sticker_fork_button.png b/sites/frontend/img/get_a_sticker_fork_button.png similarity index 100% rename from sites/en/frontend/img/get_a_sticker_fork_button.png rename to sites/frontend/img/get_a_sticker_fork_button.png diff --git a/sites/en/frontend/img/get_a_sticker_https.png b/sites/frontend/img/get_a_sticker_https.png similarity index 100% rename from sites/en/frontend/img/get_a_sticker_https.png rename to sites/frontend/img/get_a_sticker_https.png diff --git a/sites/en/frontend/img/get_a_sticker_output.png b/sites/frontend/img/get_a_sticker_output.png similarity index 100% rename from sites/en/frontend/img/get_a_sticker_output.png rename to sites/frontend/img/get_a_sticker_output.png diff --git a/sites/en/frontend/img/github_create_repo.png b/sites/frontend/img/github_create_repo.png similarity index 100% rename from sites/en/frontend/img/github_create_repo.png rename to sites/frontend/img/github_create_repo.png diff --git a/sites/en/frontend/img/github_name_your_repo.png b/sites/frontend/img/github_name_your_repo.png similarity index 100% rename from sites/en/frontend/img/github_name_your_repo.png rename to sites/frontend/img/github_name_your_repo.png diff --git a/sites/en/frontend/img/hello_html.png b/sites/frontend/img/hello_html.png similarity index 100% rename from sites/en/frontend/img/hello_html.png rename to sites/frontend/img/hello_html.png diff --git a/sites/en/frontend/img/hello_omg.png b/sites/frontend/img/hello_omg.png similarity index 100% rename from sites/en/frontend/img/hello_omg.png rename to sites/frontend/img/hello_omg.png diff --git a/sites/en/frontend/img/hello_structure.png b/sites/frontend/img/hello_structure.png similarity index 100% rename from sites/en/frontend/img/hello_structure.png rename to sites/frontend/img/hello_structure.png diff --git a/sites/en/frontend/img/hello_style.png b/sites/frontend/img/hello_style.png similarity index 100% rename from sites/en/frontend/img/hello_style.png rename to sites/frontend/img/hello_style.png diff --git a/sites/en/frontend/img/hello_title.png b/sites/frontend/img/hello_title.png similarity index 100% rename from sites/en/frontend/img/hello_title.png rename to sites/frontend/img/hello_title.png diff --git a/sites/en/frontend/img/hello_world.png b/sites/frontend/img/hello_world.png similarity index 100% rename from sites/en/frontend/img/hello_world.png rename to sites/frontend/img/hello_world.png diff --git a/sites/en/frontend/img/hello_world_2line.png b/sites/frontend/img/hello_world_2line.png similarity index 100% rename from sites/en/frontend/img/hello_world_2line.png rename to sites/frontend/img/hello_world_2line.png diff --git a/sites/en/frontend/img/hello_world_2line2.png b/sites/frontend/img/hello_world_2line2.png similarity index 100% rename from sites/en/frontend/img/hello_world_2line2.png rename to sites/frontend/img/hello_world_2line2.png diff --git a/sites/en/frontend/img/hello_world_jazzy.png b/sites/frontend/img/hello_world_jazzy.png similarity index 100% rename from sites/en/frontend/img/hello_world_jazzy.png rename to sites/frontend/img/hello_world_jazzy.png diff --git a/sites/en/frontend/img/html_tags_list.png b/sites/frontend/img/html_tags_list.png similarity index 100% rename from sites/en/frontend/img/html_tags_list.png rename to sites/frontend/img/html_tags_list.png diff --git a/sites/en/frontend/img/jquery_result.png b/sites/frontend/img/jquery_result.png similarity index 100% rename from sites/en/frontend/img/jquery_result.png rename to sites/frontend/img/jquery_result.png diff --git a/sites/en/frontend/img/page.png b/sites/frontend/img/page.png similarity index 100% rename from sites/en/frontend/img/page.png rename to sites/frontend/img/page.png diff --git a/sites/en/frontend/img/page_anchors.png b/sites/frontend/img/page_anchors.png similarity index 100% rename from sites/en/frontend/img/page_anchors.png rename to sites/frontend/img/page_anchors.png diff --git a/sites/en/frontend/img/page_html.png b/sites/frontend/img/page_html.png similarity index 100% rename from sites/en/frontend/img/page_html.png rename to sites/frontend/img/page_html.png diff --git a/sites/en/frontend/img/page_img.png b/sites/frontend/img/page_img.png similarity index 100% rename from sites/en/frontend/img/page_img.png rename to sites/frontend/img/page_img.png diff --git a/sites/en/frontend/img/page_sample.jpg b/sites/frontend/img/page_sample.jpg similarity index 100% rename from sites/en/frontend/img/page_sample.jpg rename to sites/frontend/img/page_sample.jpg diff --git a/sites/en/frontend/img/prompt.png b/sites/frontend/img/prompt.png similarity index 100% rename from sites/en/frontend/img/prompt.png rename to sites/frontend/img/prompt.png diff --git a/sites/en/frontend/img/zip.png b/sites/frontend/img/zip.png similarity index 100% rename from sites/en/frontend/img/zip.png rename to sites/frontend/img/zip.png diff --git a/sites/en/frontend/introduction_to_html.step b/sites/frontend/introduction_to_html.step similarity index 100% rename from sites/en/frontend/introduction_to_html.step rename to sites/frontend/introduction_to_html.step diff --git a/sites/en/frontend/jquery.step b/sites/frontend/jquery.step similarity index 100% rename from sites/en/frontend/jquery.step rename to sites/frontend/jquery.step diff --git a/sites/en/frontend/jquery_vs_javascript.step b/sites/frontend/jquery_vs_javascript.step similarity index 100% rename from sites/en/frontend/jquery_vs_javascript.step rename to sites/frontend/jquery_vs_javascript.step diff --git a/sites/en/frontend/make_a_web_page.step b/sites/frontend/make_a_web_page.step similarity index 100% rename from sites/en/frontend/make_a_web_page.step rename to sites/frontend/make_a_web_page.step diff --git a/sites/en/frontend/make_columns.step b/sites/frontend/make_columns.step similarity index 100% rename from sites/en/frontend/make_columns.step rename to sites/frontend/make_columns.step diff --git a/sites/en/frontend/resources.step b/sites/frontend/resources.step similarity index 100% rename from sites/en/frontend/resources.step rename to sites/frontend/resources.step diff --git a/sites/en/frontend/tool_installation.step b/sites/frontend/tool_installation.step similarity index 100% rename from sites/en/frontend/tool_installation.step rename to sites/frontend/tool_installation.step diff --git a/sites/en/frontend/zip_content/.gitignore b/sites/frontend/zip_content/.gitignore similarity index 100% rename from sites/en/frontend/zip_content/.gitignore rename to sites/frontend/zip_content/.gitignore diff --git a/sites/en/frontend/zip_content/index.html b/sites/frontend/zip_content/index.html similarity index 100% rename from sites/en/frontend/zip_content/index.html rename to sites/frontend/zip_content/index.html diff --git a/sites/en/frontend/zip_content/resources/javascript.js b/sites/frontend/zip_content/resources/javascript.js similarity index 100% rename from sites/en/frontend/zip_content/resources/javascript.js rename to sites/frontend/zip_content/resources/javascript.js diff --git a/sites/en/frontend/zip_content/resources/layout.css b/sites/frontend/zip_content/resources/layout.css similarity index 100% rename from sites/en/frontend/zip_content/resources/layout.css rename to sites/frontend/zip_content/resources/layout.css diff --git a/sites/en/frontend/zip_content/resources/picture.jpg b/sites/frontend/zip_content/resources/picture.jpg similarity index 100% rename from sites/en/frontend/zip_content/resources/picture.jpg rename to sites/frontend/zip_content/resources/picture.jpg diff --git a/sites/en/installfest/_command-line-glossary.md b/sites/installfest/_command-line-glossary.md similarity index 100% rename from sites/en/installfest/_command-line-glossary.md rename to sites/installfest/_command-line-glossary.md diff --git a/sites/en/installfest/_general-glossary.md b/sites/installfest/_general-glossary.md similarity index 100% rename from sites/en/installfest/_general-glossary.md rename to sites/installfest/_general-glossary.md diff --git a/sites/en/installfest/_install_atom_for_mac.step b/sites/installfest/_install_atom_for_mac.step similarity index 100% rename from sites/en/installfest/_install_atom_for_mac.step rename to sites/installfest/_install_atom_for_mac.step diff --git a/sites/en/installfest/_install_homebrew.step b/sites/installfest/_install_homebrew.step similarity index 100% rename from sites/en/installfest/_install_homebrew.step rename to sites/installfest/_install_homebrew.step diff --git a/sites/en/installfest/_install_ruby.step b/sites/installfest/_install_ruby.step similarity index 100% rename from sites/en/installfest/_install_ruby.step rename to sites/installfest/_install_ruby.step diff --git a/sites/en/installfest/_install_rvm.step b/sites/installfest/_install_rvm.step similarity index 100% rename from sites/en/installfest/_install_rvm.step rename to sites/installfest/_install_rvm.step diff --git a/sites/en/installfest/_install_textmate.step b/sites/installfest/_install_textmate.step similarity index 100% rename from sites/en/installfest/_install_textmate.step rename to sites/installfest/_install_textmate.step diff --git a/sites/en/installfest/_ruby-and-rails-glossary.md b/sites/installfest/_ruby-and-rails-glossary.md similarity index 100% rename from sites/en/installfest/_ruby-and-rails-glossary.md rename to sites/installfest/_ruby-and-rails-glossary.md diff --git a/sites/en/installfest/_switch_to_home_directory.step b/sites/installfest/_switch_to_home_directory.step similarity index 100% rename from sites/en/installfest/_switch_to_home_directory.step rename to sites/installfest/_switch_to_home_directory.step diff --git a/sites/en/installfest/choose_your_operating_system.step b/sites/installfest/choose_your_operating_system.step similarity index 100% rename from sites/en/installfest/choose_your_operating_system.step rename to sites/installfest/choose_your_operating_system.step diff --git a/sites/en/installfest/clean_up.step b/sites/installfest/clean_up.step similarity index 100% rename from sites/en/installfest/clean_up.step rename to sites/installfest/clean_up.step diff --git a/sites/en/installfest/configure_git.step b/sites/installfest/configure_git.step similarity index 100% rename from sites/en/installfest/configure_git.step rename to sites/installfest/configure_git.step diff --git a/sites/en/installfest/create_a_github_account.step b/sites/installfest/create_a_github_account.step similarity index 100% rename from sites/en/installfest/create_a_github_account.step rename to sites/installfest/create_a_github_account.step diff --git a/sites/en/installfest/create_a_heroku_account.step b/sites/installfest/create_a_heroku_account.step similarity index 100% rename from sites/en/installfest/create_a_heroku_account.step rename to sites/installfest/create_a_heroku_account.step diff --git a/sites/en/installfest/create_a_rails_app.step b/sites/installfest/create_a_rails_app.step similarity index 100% rename from sites/en/installfest/create_a_rails_app.step rename to sites/installfest/create_a_rails_app.step diff --git a/sites/en/installfest/create_an_ssh_key.step b/sites/installfest/create_an_ssh_key.step similarity index 100% rename from sites/en/installfest/create_an_ssh_key.step rename to sites/installfest/create_an_ssh_key.step diff --git a/sites/en/installfest/deploy_a_rails_app.step b/sites/installfest/deploy_a_rails_app.step similarity index 100% rename from sites/en/installfest/deploy_a_rails_app.step rename to sites/installfest/deploy_a_rails_app.step diff --git a/sites/en/installfest/editors.step b/sites/installfest/editors.step similarity index 100% rename from sites/en/installfest/editors.step rename to sites/installfest/editors.step diff --git a/sites/en/installfest/get_a_sticker.step b/sites/installfest/get_a_sticker.step similarity index 100% rename from sites/en/installfest/get_a_sticker.step rename to sites/installfest/get_a_sticker.step diff --git a/sites/en/installfest/glossary.step b/sites/installfest/glossary.step similarity index 100% rename from sites/en/installfest/glossary.step rename to sites/installfest/glossary.step diff --git a/sites/en/installfest/img/AboutThisMac.png b/sites/installfest/img/AboutThisMac.png similarity index 100% rename from sites/en/installfest/img/AboutThisMac.png rename to sites/installfest/img/AboutThisMac.png diff --git a/sites/en/installfest/img/WinRailsInstaller.jpg b/sites/installfest/img/WinRailsInstaller.jpg similarity index 100% rename from sites/en/installfest/img/WinRailsInstaller.jpg rename to sites/installfest/img/WinRailsInstaller.jpg diff --git a/sites/en/installfest/img/appstore.jpg b/sites/installfest/img/appstore.jpg similarity index 100% rename from sites/en/installfest/img/appstore.jpg rename to sites/installfest/img/appstore.jpg diff --git a/sites/en/installfest/img/directory.png b/sites/installfest/img/directory.png similarity index 100% rename from sites/en/installfest/img/directory.png rename to sites/installfest/img/directory.png diff --git a/sites/en/installfest/img/get_a_sticker_you_should_see.png b/sites/installfest/img/get_a_sticker_you_should_see.png similarity index 100% rename from sites/en/installfest/img/get_a_sticker_you_should_see.png rename to sites/installfest/img/get_a_sticker_you_should_see.png diff --git a/sites/en/installfest/img/install_atom_mac.gif b/sites/installfest/img/install_atom_mac.gif similarity index 100% rename from sites/en/installfest/img/install_atom_mac.gif rename to sites/installfest/img/install_atom_mac.gif diff --git a/sites/en/installfest/img/railsbridge_ubuntu12-checkbox.png b/sites/installfest/img/railsbridge_ubuntu12-checkbox.png similarity index 100% rename from sites/en/installfest/img/railsbridge_ubuntu12-checkbox.png rename to sites/installfest/img/railsbridge_ubuntu12-checkbox.png diff --git a/sites/en/installfest/img/railsbridge_windowsScreenshot-commandprompt-pinnedtotaskbar.png b/sites/installfest/img/railsbridge_windowsScreenshot-commandprompt-pinnedtotaskbar.png similarity index 100% rename from sites/en/installfest/img/railsbridge_windowsScreenshot-commandprompt-pinnedtotaskbar.png rename to sites/installfest/img/railsbridge_windowsScreenshot-commandprompt-pinnedtotaskbar.png diff --git a/sites/en/installfest/img/railsbridge_windowsScreenshot-commandprompt_ror.png b/sites/installfest/img/railsbridge_windowsScreenshot-commandprompt_ror.png similarity index 100% rename from sites/en/installfest/img/railsbridge_windowsScreenshot-commandprompt_ror.png rename to sites/installfest/img/railsbridge_windowsScreenshot-commandprompt_ror.png diff --git a/sites/en/installfest/img/railsbridge_windows_findingCommandPrompt_win7.png b/sites/installfest/img/railsbridge_windows_findingCommandPrompt_win7.png similarity index 100% rename from sites/en/installfest/img/railsbridge_windows_findingCommandPrompt_win7.png rename to sites/installfest/img/railsbridge_windows_findingCommandPrompt_win7.png diff --git a/sites/en/installfest/img/railsbridge_windows_findingCommandPrompt_win8.png b/sites/installfest/img/railsbridge_windows_findingCommandPrompt_win8.png similarity index 100% rename from sites/en/installfest/img/railsbridge_windows_findingCommandPrompt_win8.png rename to sites/installfest/img/railsbridge_windows_findingCommandPrompt_win8.png diff --git a/sites/en/installfest/img/successful_rails_install.png b/sites/installfest/img/successful_rails_install.png similarity index 100% rename from sites/en/installfest/img/successful_rails_install.png rename to sites/installfest/img/successful_rails_install.png diff --git a/sites/en/installfest/img/xcode-prefs.jpg b/sites/installfest/img/xcode-prefs.jpg similarity index 100% rename from sites/en/installfest/img/xcode-prefs.jpg rename to sites/installfest/img/xcode-prefs.jpg diff --git a/sites/en/installfest/img/xcode-tools-install.png b/sites/installfest/img/xcode-tools-install.png similarity index 100% rename from sites/en/installfest/img/xcode-tools-install.png rename to sites/installfest/img/xcode-tools-install.png diff --git a/sites/en/installfest/install_xcode.step b/sites/installfest/install_xcode.step similarity index 100% rename from sites/en/installfest/install_xcode.step rename to sites/installfest/install_xcode.step diff --git a/sites/en/installfest/install_xcode_command_line_tools.step b/sites/installfest/install_xcode_command_line_tools.step similarity index 100% rename from sites/en/installfest/install_xcode_command_line_tools.step rename to sites/installfest/install_xcode_command_line_tools.step diff --git a/sites/en/installfest/install_xcode_from_app_store.step b/sites/installfest/install_xcode_from_app_store.step similarity index 100% rename from sites/en/installfest/install_xcode_from_app_store.step rename to sites/installfest/install_xcode_from_app_store.step diff --git a/sites/en/installfest/install_xcode_from_dvd.step b/sites/installfest/install_xcode_from_dvd.step similarity index 100% rename from sites/en/installfest/install_xcode_from_dvd.step rename to sites/installfest/install_xcode_from_dvd.step diff --git a/sites/en/installfest/installfest.step b/sites/installfest/installfest.step similarity index 100% rename from sites/en/installfest/installfest.step rename to sites/installfest/installfest.step diff --git a/sites/en/installfest/linux.step b/sites/installfest/linux.step similarity index 100% rename from sites/en/installfest/linux.step rename to sites/installfest/linux.step diff --git a/sites/en/installfest/macOS.step b/sites/installfest/macOS.step similarity index 100% rename from sites/en/installfest/macOS.step rename to sites/installfest/macOS.step diff --git a/sites/en/installfest/osx_rvm.step b/sites/installfest/osx_rvm.step similarity index 100% rename from sites/en/installfest/osx_rvm.step rename to sites/installfest/osx_rvm.step diff --git a/sites/en/installfest/windows.step b/sites/installfest/windows.step similarity index 100% rename from sites/en/installfest/windows.step rename to sites/installfest/windows.step diff --git a/sites/en/intro-to-rails/CRUD_with_scaffolding.step b/sites/intro-to-rails/CRUD_with_scaffolding.step similarity index 100% rename from sites/en/intro-to-rails/CRUD_with_scaffolding.step rename to sites/intro-to-rails/CRUD_with_scaffolding.step diff --git a/sites/en/intro-to-rails/_consider_deploying.step b/sites/intro-to-rails/_consider_deploying.step similarity index 100% rename from sites/en/intro-to-rails/_consider_deploying.step rename to sites/intro-to-rails/_consider_deploying.step diff --git a/sites/en/intro-to-rails/_consider_deploying_again.step b/sites/intro-to-rails/_consider_deploying_again.step similarity index 100% rename from sites/en/intro-to-rails/_consider_deploying_again.step rename to sites/intro-to-rails/_consider_deploying_again.step diff --git a/sites/en/intro-to-rails/_deploying_to_heroku.step b/sites/intro-to-rails/_deploying_to_heroku.step similarity index 100% rename from sites/en/intro-to-rails/_deploying_to_heroku.step rename to sites/intro-to-rails/_deploying_to_heroku.step diff --git a/sites/en/intro-to-rails/_deploying_to_heroku_again.step b/sites/intro-to-rails/_deploying_to_heroku_again.step similarity index 100% rename from sites/en/intro-to-rails/_deploying_to_heroku_again.step rename to sites/intro-to-rails/_deploying_to_heroku_again.step diff --git a/sites/en/intro-to-rails/_switch_to_home_directory.step b/sites/intro-to-rails/_switch_to_home_directory.step similarity index 100% rename from sites/en/intro-to-rails/_switch_to_home_directory.step rename to sites/intro-to-rails/_switch_to_home_directory.step diff --git a/sites/en/intro-to-rails/_working_effectively_and_efficiently.md b/sites/intro-to-rails/_working_effectively_and_efficiently.md similarity index 100% rename from sites/en/intro-to-rails/_working_effectively_and_efficiently.md rename to sites/intro-to-rails/_working_effectively_and_efficiently.md diff --git a/sites/en/intro-to-rails/add_the_project_to_a_git_repo.step b/sites/intro-to-rails/add_the_project_to_a_git_repo.step similarity index 100% rename from sites/en/intro-to-rails/add_the_project_to_a_git_repo.step rename to sites/intro-to-rails/add_the_project_to_a_git_repo.step diff --git a/sites/en/intro-to-rails/allow_people_to_vote.step b/sites/intro-to-rails/allow_people_to_vote.step similarity index 100% rename from sites/en/intro-to-rails/allow_people_to_vote.step rename to sites/intro-to-rails/allow_people_to_vote.step diff --git a/sites/en/intro-to-rails/clean_up_links_on_the_topics_list.step b/sites/intro-to-rails/clean_up_links_on_the_topics_list.step similarity index 100% rename from sites/en/intro-to-rails/clean_up_links_on_the_topics_list.step rename to sites/intro-to-rails/clean_up_links_on_the_topics_list.step diff --git a/sites/en/intro-to-rails/creating_a_migration.step b/sites/intro-to-rails/creating_a_migration.step similarity index 100% rename from sites/en/intro-to-rails/creating_a_migration.step rename to sites/intro-to-rails/creating_a_migration.step diff --git a/sites/en/intro-to-rails/credits_and_next_steps.step b/sites/intro-to-rails/credits_and_next_steps.step similarity index 100% rename from sites/en/intro-to-rails/credits_and_next_steps.step rename to sites/intro-to-rails/credits_and_next_steps.step diff --git a/sites/en/intro-to-rails/deploying_to_heroku.step b/sites/intro-to-rails/deploying_to_heroku.step similarity index 100% rename from sites/en/intro-to-rails/deploying_to_heroku.step rename to sites/intro-to-rails/deploying_to_heroku.step diff --git a/sites/en/intro-to-rails/deploying_to_heroku_again.step b/sites/intro-to-rails/deploying_to_heroku_again.step similarity index 100% rename from sites/en/intro-to-rails/deploying_to_heroku_again.step rename to sites/intro-to-rails/deploying_to_heroku_again.step diff --git a/sites/en/intro-to-rails/getting_started.step b/sites/intro-to-rails/getting_started.step similarity index 100% rename from sites/en/intro-to-rails/getting_started.step rename to sites/intro-to-rails/getting_started.step diff --git a/sites/en/intro-to-rails/glossary.step b/sites/intro-to-rails/glossary.step similarity index 100% rename from sites/en/intro-to-rails/glossary.step rename to sites/intro-to-rails/glossary.step diff --git a/sites/en/intro-to-rails/hooking_up_votes_and_topics.step b/sites/intro-to-rails/hooking_up_votes_and_topics.step similarity index 100% rename from sites/en/intro-to-rails/hooking_up_votes_and_topics.step rename to sites/intro-to-rails/hooking_up_votes_and_topics.step diff --git a/sites/en/intro-to-rails/img/Seattle_list_with_topic.png b/sites/intro-to-rails/img/Seattle_list_with_topic.png similarity index 100% rename from sites/en/intro-to-rails/img/Seattle_list_with_topic.png rename to sites/intro-to-rails/img/Seattle_list_with_topic.png diff --git a/sites/en/intro-to-rails/img/Seattle_topic_created.png b/sites/intro-to-rails/img/Seattle_topic_created.png similarity index 100% rename from sites/en/intro-to-rails/img/Seattle_topic_created.png rename to sites/intro-to-rails/img/Seattle_topic_created.png diff --git a/sites/en/intro-to-rails/img/Seattle_topic_list_page.png b/sites/intro-to-rails/img/Seattle_topic_list_page.png similarity index 100% rename from sites/en/intro-to-rails/img/Seattle_topic_list_page.png rename to sites/intro-to-rails/img/Seattle_topic_list_page.png diff --git a/sites/en/intro-to-rails/img/Start_page.png b/sites/intro-to-rails/img/Start_page.png similarity index 100% rename from sites/en/intro-to-rails/img/Start_page.png rename to sites/intro-to-rails/img/Start_page.png diff --git a/sites/en/intro-to-rails/img/atom_add_folder_to_project.png b/sites/intro-to-rails/img/atom_add_folder_to_project.png similarity index 100% rename from sites/en/intro-to-rails/img/atom_add_folder_to_project.png rename to sites/intro-to-rails/img/atom_add_folder_to_project.png diff --git a/sites/en/intro-to-rails/img/atom_project_as_folder.png b/sites/intro-to-rails/img/atom_project_as_folder.png similarity index 100% rename from sites/en/intro-to-rails/img/atom_project_as_folder.png rename to sites/intro-to-rails/img/atom_project_as_folder.png diff --git a/sites/en/intro-to-rails/img/finished_app.png b/sites/intro-to-rails/img/finished_app.png similarity index 100% rename from sites/en/intro-to-rails/img/finished_app.png rename to sites/intro-to-rails/img/finished_app.png diff --git a/sites/en/intro-to-rails/img/mvc.png b/sites/intro-to-rails/img/mvc.png similarity index 100% rename from sites/en/intro-to-rails/img/mvc.png rename to sites/intro-to-rails/img/mvc.png diff --git a/sites/en/intro-to-rails/img/rails4_rails_info_routing.png b/sites/intro-to-rails/img/rails4_rails_info_routing.png similarity index 100% rename from sites/en/intro-to-rails/img/rails4_rails_info_routing.png rename to sites/intro-to-rails/img/rails4_rails_info_routing.png diff --git a/sites/en/intro-to-rails/img/workflow.png b/sites/intro-to-rails/img/workflow.png similarity index 100% rename from sites/en/intro-to-rails/img/workflow.png rename to sites/intro-to-rails/img/workflow.png diff --git a/sites/en/intro-to-rails/intro-to-rails.step b/sites/intro-to-rails/intro-to-rails.step similarity index 100% rename from sites/en/intro-to-rails/intro-to-rails.step rename to sites/intro-to-rails/intro-to-rails.step diff --git a/sites/en/intro-to-rails/make_the_topic_title_a_link.step b/sites/intro-to-rails/make_the_topic_title_a_link.step similarity index 100% rename from sites/en/intro-to-rails/make_the_topic_title_a_link.step rename to sites/intro-to-rails/make_the_topic_title_a_link.step diff --git a/sites/en/intro-to-rails/rails_architecture.step b/sites/intro-to-rails/rails_architecture.step similarity index 100% rename from sites/en/intro-to-rails/rails_architecture.step rename to sites/intro-to-rails/rails_architecture.step diff --git a/sites/en/intro-to-rails/redirect_to_the_topics_list_after_creating_a_new_topic.step b/sites/intro-to-rails/redirect_to_the_topics_list_after_creating_a_new_topic.step similarity index 100% rename from sites/en/intro-to-rails/redirect_to_the_topics_list_after_creating_a_new_topic.step rename to sites/intro-to-rails/redirect_to_the_topics_list_after_creating_a_new_topic.step diff --git a/sites/en/intro-to-rails/ruby_language.step b/sites/intro-to-rails/ruby_language.step similarity index 100% rename from sites/en/intro-to-rails/ruby_language.step rename to sites/intro-to-rails/ruby_language.step diff --git a/sites/en/intro-to-rails/running_your_application_locally.step b/sites/intro-to-rails/running_your_application_locally.step similarity index 100% rename from sites/en/intro-to-rails/running_your_application_locally.step rename to sites/intro-to-rails/running_your_application_locally.step diff --git a/sites/en/intro-to-rails/setting_the_default_page.step b/sites/intro-to-rails/setting_the_default_page.step similarity index 100% rename from sites/en/intro-to-rails/setting_the_default_page.step rename to sites/intro-to-rails/setting_the_default_page.step diff --git a/sites/en/intro-to-rails/voting_on_topics.step b/sites/intro-to-rails/voting_on_topics.step similarity index 100% rename from sites/en/intro-to-rails/voting_on_topics.step rename to sites/intro-to-rails/voting_on_topics.step diff --git a/sites/en/javascript-snake-game/img/browser_console.png b/sites/javascript-snake-game/img/browser_console.png similarity index 100% rename from sites/en/javascript-snake-game/img/browser_console.png rename to sites/javascript-snake-game/img/browser_console.png diff --git a/sites/en/javascript-snake-game/javascript-snake-game.step b/sites/javascript-snake-game/javascript-snake-game.step similarity index 100% rename from sites/en/javascript-snake-game/javascript-snake-game.step rename to sites/javascript-snake-game/javascript-snake-game.step diff --git a/sites/en/javascript-snake-game/js-snake-game-tutorial.zip-manifest b/sites/javascript-snake-game/js-snake-game-tutorial.zip-manifest similarity index 100% rename from sites/en/javascript-snake-game/js-snake-game-tutorial.zip-manifest rename to sites/javascript-snake-game/js-snake-game-tutorial.zip-manifest diff --git a/sites/en/javascript-snake-game/js/chunk.js b/sites/javascript-snake-game/js/chunk.js similarity index 100% rename from sites/en/javascript-snake-game/js/chunk.js rename to sites/javascript-snake-game/js/chunk.js diff --git a/sites/en/javascript-snake-game/js/lesson-10.js b/sites/javascript-snake-game/js/lesson-10.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-10.js rename to sites/javascript-snake-game/js/lesson-10.js diff --git a/sites/en/javascript-snake-game/js/lesson-11.js b/sites/javascript-snake-game/js/lesson-11.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-11.js rename to sites/javascript-snake-game/js/lesson-11.js diff --git a/sites/en/javascript-snake-game/js/lesson-12.js b/sites/javascript-snake-game/js/lesson-12.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-12.js rename to sites/javascript-snake-game/js/lesson-12.js diff --git a/sites/en/javascript-snake-game/js/lesson-13.js b/sites/javascript-snake-game/js/lesson-13.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-13.js rename to sites/javascript-snake-game/js/lesson-13.js diff --git a/sites/en/javascript-snake-game/js/lesson-2.js b/sites/javascript-snake-game/js/lesson-2.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-2.js rename to sites/javascript-snake-game/js/lesson-2.js diff --git a/sites/en/javascript-snake-game/js/lesson-3.js b/sites/javascript-snake-game/js/lesson-3.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-3.js rename to sites/javascript-snake-game/js/lesson-3.js diff --git a/sites/en/javascript-snake-game/js/lesson-4.js b/sites/javascript-snake-game/js/lesson-4.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-4.js rename to sites/javascript-snake-game/js/lesson-4.js diff --git a/sites/en/javascript-snake-game/js/lesson-5.js b/sites/javascript-snake-game/js/lesson-5.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-5.js rename to sites/javascript-snake-game/js/lesson-5.js diff --git a/sites/en/javascript-snake-game/js/lesson-6.js b/sites/javascript-snake-game/js/lesson-6.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-6.js rename to sites/javascript-snake-game/js/lesson-6.js diff --git a/sites/en/javascript-snake-game/js/lesson-7.js b/sites/javascript-snake-game/js/lesson-7.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-7.js rename to sites/javascript-snake-game/js/lesson-7.js diff --git a/sites/en/javascript-snake-game/js/lesson-8.js b/sites/javascript-snake-game/js/lesson-8.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-8.js rename to sites/javascript-snake-game/js/lesson-8.js diff --git a/sites/en/javascript-snake-game/js/lesson-9.js b/sites/javascript-snake-game/js/lesson-9.js similarity index 100% rename from sites/en/javascript-snake-game/js/lesson-9.js rename to sites/javascript-snake-game/js/lesson-9.js diff --git a/sites/en/javascript-snake-game/js/snake.js b/sites/javascript-snake-game/js/snake.js similarity index 100% rename from sites/en/javascript-snake-game/js/snake.js rename to sites/javascript-snake-game/js/snake.js diff --git a/sites/en/javascript-snake-game/lesson-1.step b/sites/javascript-snake-game/lesson-1.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-1.step rename to sites/javascript-snake-game/lesson-1.step diff --git a/sites/en/javascript-snake-game/lesson-10.step b/sites/javascript-snake-game/lesson-10.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-10.step rename to sites/javascript-snake-game/lesson-10.step diff --git a/sites/en/javascript-snake-game/lesson-11.step b/sites/javascript-snake-game/lesson-11.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-11.step rename to sites/javascript-snake-game/lesson-11.step diff --git a/sites/en/javascript-snake-game/lesson-12.step b/sites/javascript-snake-game/lesson-12.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-12.step rename to sites/javascript-snake-game/lesson-12.step diff --git a/sites/en/javascript-snake-game/lesson-13.step b/sites/javascript-snake-game/lesson-13.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-13.step rename to sites/javascript-snake-game/lesson-13.step diff --git a/sites/en/javascript-snake-game/lesson-14.step b/sites/javascript-snake-game/lesson-14.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-14.step rename to sites/javascript-snake-game/lesson-14.step diff --git a/sites/en/javascript-snake-game/lesson-2.step b/sites/javascript-snake-game/lesson-2.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-2.step rename to sites/javascript-snake-game/lesson-2.step diff --git a/sites/en/javascript-snake-game/lesson-3.step b/sites/javascript-snake-game/lesson-3.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-3.step rename to sites/javascript-snake-game/lesson-3.step diff --git a/sites/en/javascript-snake-game/lesson-4.step b/sites/javascript-snake-game/lesson-4.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-4.step rename to sites/javascript-snake-game/lesson-4.step diff --git a/sites/en/javascript-snake-game/lesson-5.step b/sites/javascript-snake-game/lesson-5.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-5.step rename to sites/javascript-snake-game/lesson-5.step diff --git a/sites/en/javascript-snake-game/lesson-6.step b/sites/javascript-snake-game/lesson-6.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-6.step rename to sites/javascript-snake-game/lesson-6.step diff --git a/sites/en/javascript-snake-game/lesson-7.step b/sites/javascript-snake-game/lesson-7.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-7.step rename to sites/javascript-snake-game/lesson-7.step diff --git a/sites/en/javascript-snake-game/lesson-8.step b/sites/javascript-snake-game/lesson-8.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-8.step rename to sites/javascript-snake-game/lesson-8.step diff --git a/sites/en/javascript-snake-game/lesson-9.step b/sites/javascript-snake-game/lesson-9.step similarity index 100% rename from sites/en/javascript-snake-game/lesson-9.step rename to sites/javascript-snake-game/lesson-9.step diff --git a/sites/en/javascript-snake-game/zip_content/index.html b/sites/javascript-snake-game/zip_content/index.html similarity index 100% rename from sites/en/javascript-snake-game/zip_content/index.html rename to sites/javascript-snake-game/zip_content/index.html diff --git a/sites/en/javascript-snake-game/zip_content/snake.js b/sites/javascript-snake-game/zip_content/snake.js similarity index 100% rename from sites/en/javascript-snake-game/zip_content/snake.js rename to sites/javascript-snake-game/zip_content/snake.js diff --git a/sites/en/javascript-to-do-list-with-react/AdvancedTodoList.zip-manifest b/sites/javascript-to-do-list-with-react/AdvancedTodoList.zip-manifest similarity index 100% rename from sites/en/javascript-to-do-list-with-react/AdvancedTodoList.zip-manifest rename to sites/javascript-to-do-list-with-react/AdvancedTodoList.zip-manifest diff --git a/sites/en/javascript-to-do-list-with-react/adding_an_item.step b/sites/javascript-to-do-list-with-react/adding_an_item.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/adding_an_item.step rename to sites/javascript-to-do-list-with-react/adding_an_item.step diff --git a/sites/en/javascript-to-do-list-with-react/building_complex_applications_with_react.step b/sites/javascript-to-do-list-with-react/building_complex_applications_with_react.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/building_complex_applications_with_react.step rename to sites/javascript-to-do-list-with-react/building_complex_applications_with_react.step diff --git a/sites/en/javascript-to-do-list-with-react/creating_a_list.step b/sites/javascript-to-do-list-with-react/creating_a_list.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/creating_a_list.step rename to sites/javascript-to-do-list-with-react/creating_a_list.step diff --git a/sites/en/javascript-to-do-list-with-react/deploying_your_site.step b/sites/javascript-to-do-list-with-react/deploying_your_site.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/deploying_your_site.step rename to sites/javascript-to-do-list-with-react/deploying_your_site.step diff --git a/sites/en/javascript-to-do-list-with-react/developer_tools.step b/sites/javascript-to-do-list-with-react/developer_tools.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/developer_tools.step rename to sites/javascript-to-do-list-with-react/developer_tools.step diff --git a/sites/en/javascript-to-do-list-with-react/javascript-to-do-list-with-react.step b/sites/javascript-to-do-list-with-react/javascript-to-do-list-with-react.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/javascript-to-do-list-with-react.step rename to sites/javascript-to-do-list-with-react/javascript-to-do-list-with-react.step diff --git a/sites/en/javascript-to-do-list-with-react/loading_items.step b/sites/javascript-to-do-list-with-react/loading_items.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/loading_items.step rename to sites/javascript-to-do-list-with-react/loading_items.step diff --git a/sites/en/javascript-to-do-list-with-react/marking_an_item_as_complete.step b/sites/javascript-to-do-list-with-react/marking_an_item_as_complete.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/marking_an_item_as_complete.step rename to sites/javascript-to-do-list-with-react/marking_an_item_as_complete.step diff --git a/sites/en/javascript-to-do-list-with-react/next_steps.step b/sites/javascript-to-do-list-with-react/next_steps.step similarity index 100% rename from sites/en/javascript-to-do-list-with-react/next_steps.step rename to sites/javascript-to-do-list-with-react/next_steps.step diff --git a/sites/en/javascript-to-do-list-with-react/zip_content/app.js b/sites/javascript-to-do-list-with-react/zip_content/app.js similarity index 100% rename from sites/en/javascript-to-do-list-with-react/zip_content/app.js rename to sites/javascript-to-do-list-with-react/zip_content/app.js diff --git a/sites/en/javascript-to-do-list-with-react/zip_content/console-polyfill.js b/sites/javascript-to-do-list-with-react/zip_content/console-polyfill.js similarity index 100% rename from sites/en/javascript-to-do-list-with-react/zip_content/console-polyfill.js rename to sites/javascript-to-do-list-with-react/zip_content/console-polyfill.js diff --git a/sites/en/javascript-to-do-list-with-react/zip_content/debut_light.png b/sites/javascript-to-do-list-with-react/zip_content/debut_light.png similarity index 100% rename from sites/en/javascript-to-do-list-with-react/zip_content/debut_light.png rename to sites/javascript-to-do-list-with-react/zip_content/debut_light.png diff --git a/sites/en/javascript-to-do-list-with-react/zip_content/index.html b/sites/javascript-to-do-list-with-react/zip_content/index.html similarity index 100% rename from sites/en/javascript-to-do-list-with-react/zip_content/index.html rename to sites/javascript-to-do-list-with-react/zip_content/index.html diff --git a/sites/en/javascript-to-do-list-with-react/zip_content/store.js b/sites/javascript-to-do-list-with-react/zip_content/store.js similarity index 100% rename from sites/en/javascript-to-do-list-with-react/zip_content/store.js rename to sites/javascript-to-do-list-with-react/zip_content/store.js diff --git a/sites/en/javascript-to-do-list-with-react/zip_content/styles.css b/sites/javascript-to-do-list-with-react/zip_content/styles.css similarity index 100% rename from sites/en/javascript-to-do-list-with-react/zip_content/styles.css rename to sites/javascript-to-do-list-with-react/zip_content/styles.css diff --git a/sites/en/javascript-to-do-list/IntermediateTodoList.zip-manifest b/sites/javascript-to-do-list/IntermediateTodoList.zip-manifest similarity index 100% rename from sites/en/javascript-to-do-list/IntermediateTodoList.zip-manifest rename to sites/javascript-to-do-list/IntermediateTodoList.zip-manifest diff --git a/sites/en/javascript-to-do-list/_deploying_your_site.md b/sites/javascript-to-do-list/_deploying_your_site.md similarity index 100% rename from sites/en/javascript-to-do-list/_deploying_your_site.md rename to sites/javascript-to-do-list/_deploying_your_site.md diff --git a/sites/en/javascript-to-do-list/_lesson_format.md b/sites/javascript-to-do-list/_lesson_format.md similarity index 100% rename from sites/en/javascript-to-do-list/_lesson_format.md rename to sites/javascript-to-do-list/_lesson_format.md diff --git a/sites/en/javascript-to-do-list/_teachers_note.md b/sites/javascript-to-do-list/_teachers_note.md similarity index 100% rename from sites/en/javascript-to-do-list/_teachers_note.md rename to sites/javascript-to-do-list/_teachers_note.md diff --git a/sites/en/javascript-to-do-list/adding_an_item.step b/sites/javascript-to-do-list/adding_an_item.step similarity index 100% rename from sites/en/javascript-to-do-list/adding_an_item.step rename to sites/javascript-to-do-list/adding_an_item.step diff --git a/sites/en/javascript-to-do-list/creating_a_list.step b/sites/javascript-to-do-list/creating_a_list.step similarity index 100% rename from sites/en/javascript-to-do-list/creating_a_list.step rename to sites/javascript-to-do-list/creating_a_list.step diff --git a/sites/en/javascript-to-do-list/deploying_your_site.step b/sites/javascript-to-do-list/deploying_your_site.step similarity index 100% rename from sites/en/javascript-to-do-list/deploying_your_site.step rename to sites/javascript-to-do-list/deploying_your_site.step diff --git a/sites/en/javascript-to-do-list/developer_tools.step b/sites/javascript-to-do-list/developer_tools.step similarity index 100% rename from sites/en/javascript-to-do-list/developer_tools.step rename to sites/javascript-to-do-list/developer_tools.step diff --git a/sites/en/javascript-to-do-list/img/browser_console.png b/sites/javascript-to-do-list/img/browser_console.png similarity index 100% rename from sites/en/javascript-to-do-list/img/browser_console.png rename to sites/javascript-to-do-list/img/browser_console.png diff --git a/sites/en/javascript-to-do-list/img/finished_app.png b/sites/javascript-to-do-list/img/finished_app.png similarity index 100% rename from sites/en/javascript-to-do-list/img/finished_app.png rename to sites/javascript-to-do-list/img/finished_app.png diff --git a/sites/en/javascript-to-do-list/img/network_tab.png b/sites/javascript-to-do-list/img/network_tab.png similarity index 100% rename from sites/en/javascript-to-do-list/img/network_tab.png rename to sites/javascript-to-do-list/img/network_tab.png diff --git a/sites/en/javascript-to-do-list/img/text_editor_html.png b/sites/javascript-to-do-list/img/text_editor_html.png similarity index 100% rename from sites/en/javascript-to-do-list/img/text_editor_html.png rename to sites/javascript-to-do-list/img/text_editor_html.png diff --git a/sites/en/javascript-to-do-list/javascript-to-do-list.step b/sites/javascript-to-do-list/javascript-to-do-list.step similarity index 100% rename from sites/en/javascript-to-do-list/javascript-to-do-list.step rename to sites/javascript-to-do-list/javascript-to-do-list.step diff --git a/sites/en/javascript-to-do-list/loading_items.step b/sites/javascript-to-do-list/loading_items.step similarity index 100% rename from sites/en/javascript-to-do-list/loading_items.step rename to sites/javascript-to-do-list/loading_items.step diff --git a/sites/en/javascript-to-do-list/marking_an_item_as_complete.step b/sites/javascript-to-do-list/marking_an_item_as_complete.step similarity index 100% rename from sites/en/javascript-to-do-list/marking_an_item_as_complete.step rename to sites/javascript-to-do-list/marking_an_item_as_complete.step diff --git a/sites/en/javascript-to-do-list/next_steps.step b/sites/javascript-to-do-list/next_steps.step similarity index 100% rename from sites/en/javascript-to-do-list/next_steps.step rename to sites/javascript-to-do-list/next_steps.step diff --git a/sites/en/javascript-to-do-list/playing_with_jquery.step b/sites/javascript-to-do-list/playing_with_jquery.step similarity index 100% rename from sites/en/javascript-to-do-list/playing_with_jquery.step rename to sites/javascript-to-do-list/playing_with_jquery.step diff --git a/sites/en/javascript-to-do-list/programming_with_javascript.step b/sites/javascript-to-do-list/programming_with_javascript.step similarity index 100% rename from sites/en/javascript-to-do-list/programming_with_javascript.step rename to sites/javascript-to-do-list/programming_with_javascript.step diff --git a/sites/en/javascript-to-do-list/the_basics_of_a_website.step b/sites/javascript-to-do-list/the_basics_of_a_website.step similarity index 100% rename from sites/en/javascript-to-do-list/the_basics_of_a_website.step rename to sites/javascript-to-do-list/the_basics_of_a_website.step diff --git a/sites/en/javascript-to-do-list/zip_content/app.js b/sites/javascript-to-do-list/zip_content/app.js similarity index 100% rename from sites/en/javascript-to-do-list/zip_content/app.js rename to sites/javascript-to-do-list/zip_content/app.js diff --git a/sites/en/javascript-to-do-list/zip_content/debut_light.png b/sites/javascript-to-do-list/zip_content/debut_light.png similarity index 100% rename from sites/en/javascript-to-do-list/zip_content/debut_light.png rename to sites/javascript-to-do-list/zip_content/debut_light.png diff --git a/sites/en/javascript-to-do-list/zip_content/index.html b/sites/javascript-to-do-list/zip_content/index.html similarity index 100% rename from sites/en/javascript-to-do-list/zip_content/index.html rename to sites/javascript-to-do-list/zip_content/index.html diff --git a/sites/en/javascript-to-do-list/zip_content/styles.css b/sites/javascript-to-do-list/zip_content/styles.css similarity index 100% rename from sites/en/javascript-to-do-list/zip_content/styles.css rename to sites/javascript-to-do-list/zip_content/styles.css diff --git a/sites/en/job-board/add_a_navbar.step b/sites/job-board/add_a_navbar.step similarity index 100% rename from sites/en/job-board/add_a_navbar.step rename to sites/job-board/add_a_navbar.step diff --git a/sites/en/job-board/add_a_new_job_form.step b/sites/job-board/add_a_new_job_form.step similarity index 100% rename from sites/en/job-board/add_a_new_job_form.step rename to sites/job-board/add_a_new_job_form.step diff --git a/sites/en/job-board/add_more_things.step b/sites/job-board/add_more_things.step similarity index 100% rename from sites/en/job-board/add_more_things.step rename to sites/job-board/add_more_things.step diff --git a/sites/en/job-board/create_a_rails_app.step b/sites/job-board/create_a_rails_app.step similarity index 100% rename from sites/en/job-board/create_a_rails_app.step rename to sites/job-board/create_a_rails_app.step diff --git a/sites/en/job-board/crud_and_resourceful_routing.step b/sites/job-board/crud_and_resourceful_routing.step similarity index 100% rename from sites/en/job-board/crud_and_resourceful_routing.step rename to sites/job-board/crud_and_resourceful_routing.step diff --git a/sites/en/job-board/delete_job_listings.step b/sites/job-board/delete_job_listings.step similarity index 100% rename from sites/en/job-board/delete_job_listings.step rename to sites/job-board/delete_job_listings.step diff --git a/sites/en/job-board/img/crud_grid.jpg b/sites/job-board/img/crud_grid.jpg similarity index 100% rename from sites/en/job-board/img/crud_grid.jpg rename to sites/job-board/img/crud_grid.jpg diff --git a/sites/en/job-board/img/crud_rails_methods.jpg b/sites/job-board/img/crud_rails_methods.jpg similarity index 100% rename from sites/en/job-board/img/crud_rails_methods.jpg rename to sites/job-board/img/crud_rails_methods.jpg diff --git a/sites/en/job-board/img/rails-routes.png b/sites/job-board/img/rails-routes.png similarity index 100% rename from sites/en/job-board/img/rails-routes.png rename to sites/job-board/img/rails-routes.png diff --git a/sites/en/job-board/img/request-cycle.jpg b/sites/job-board/img/request-cycle.jpg similarity index 100% rename from sites/en/job-board/img/request-cycle.jpg rename to sites/job-board/img/request-cycle.jpg diff --git a/sites/en/job-board/job-board.step b/sites/job-board/job-board.step similarity index 100% rename from sites/en/job-board/job-board.step rename to sites/job-board/job-board.step diff --git a/sites/en/job-board/listing_the_jobs.step b/sites/job-board/listing_the_jobs.step similarity index 100% rename from sites/en/job-board/listing_the_jobs.step rename to sites/job-board/listing_the_jobs.step diff --git a/sites/en/job-board/make_a_jobs_home_page.step b/sites/job-board/make_a_jobs_home_page.step similarity index 100% rename from sites/en/job-board/make_a_jobs_home_page.step rename to sites/job-board/make_a_jobs_home_page.step diff --git a/sites/en/job-board/make_the_form_work.step b/sites/job-board/make_the_form_work.step similarity index 100% rename from sites/en/job-board/make_the_form_work.step rename to sites/job-board/make_the_form_work.step diff --git a/sites/en/job-board/store_jobs_in_the_database.step b/sites/job-board/store_jobs_in_the_database.step similarity index 100% rename from sites/en/job-board/store_jobs_in_the_database.step rename to sites/job-board/store_jobs_in_the_database.step diff --git a/sites/en/job-board/the_request_cycle.step b/sites/job-board/the_request_cycle.step similarity index 100% rename from sites/en/job-board/the_request_cycle.step rename to sites/job-board/the_request_cycle.step diff --git a/sites/en/job-board/update_job_listings.step b/sites/job-board/update_job_listings.step similarity index 100% rename from sites/en/job-board/update_job_listings.step rename to sites/job-board/update_job_listings.step diff --git a/sites/en/learn-to-code/argv.md b/sites/learn-to-code/argv.md similarity index 100% rename from sites/en/learn-to-code/argv.md rename to sites/learn-to-code/argv.md diff --git a/sites/en/learn-to-code/arrays.md b/sites/learn-to-code/arrays.md similarity index 100% rename from sites/en/learn-to-code/arrays.md rename to sites/learn-to-code/arrays.md diff --git a/sites/en/learn-to-code/computers.md b/sites/learn-to-code/computers.md similarity index 100% rename from sites/en/learn-to-code/computers.md rename to sites/learn-to-code/computers.md diff --git a/sites/en/learn-to-code/extra.md b/sites/learn-to-code/extra.md similarity index 100% rename from sites/en/learn-to-code/extra.md rename to sites/learn-to-code/extra.md diff --git a/sites/en/learn-to-code/functions.md b/sites/learn-to-code/functions.md similarity index 100% rename from sites/en/learn-to-code/functions.md rename to sites/learn-to-code/functions.md diff --git a/sites/en/learn-to-code/hashes.md b/sites/learn-to-code/hashes.md similarity index 100% rename from sites/en/learn-to-code/hashes.md rename to sites/learn-to-code/hashes.md diff --git a/sites/en/learn-to-code/img/cookie-recipe.gif b/sites/learn-to-code/img/cookie-recipe.gif similarity index 100% rename from sites/en/learn-to-code/img/cookie-recipe.gif rename to sites/learn-to-code/img/cookie-recipe.gif diff --git a/sites/en/learn-to-code/img/dot.jpg b/sites/learn-to-code/img/dot.jpg similarity index 100% rename from sites/en/learn-to-code/img/dot.jpg rename to sites/learn-to-code/img/dot.jpg diff --git a/sites/en/learn-to-code/img/fruit-banana-snack-banana.svg b/sites/learn-to-code/img/fruit-banana-snack-banana.svg similarity index 100% rename from sites/en/learn-to-code/img/fruit-banana-snack-banana.svg rename to sites/learn-to-code/img/fruit-banana-snack-banana.svg diff --git a/sites/en/learn-to-code/img/one-infinite-loop.jpg b/sites/learn-to-code/img/one-infinite-loop.jpg similarity index 100% rename from sites/en/learn-to-code/img/one-infinite-loop.jpg rename to sites/learn-to-code/img/one-infinite-loop.jpg diff --git a/sites/en/learn-to-code/img/snack-apple.svg b/sites/learn-to-code/img/snack-apple.svg similarity index 100% rename from sites/en/learn-to-code/img/snack-apple.svg rename to sites/learn-to-code/img/snack-apple.svg diff --git a/sites/en/learn-to-code/img/snack-fruit.svg b/sites/learn-to-code/img/snack-fruit.svg similarity index 100% rename from sites/en/learn-to-code/img/snack-fruit.svg rename to sites/learn-to-code/img/snack-fruit.svg diff --git a/sites/en/learn-to-code/img/spoon.jpg b/sites/learn-to-code/img/spoon.jpg similarity index 100% rename from sites/en/learn-to-code/img/spoon.jpg rename to sites/learn-to-code/img/spoon.jpg diff --git a/sites/en/learn-to-code/img/truthiness.png b/sites/learn-to-code/img/truthiness.png similarity index 100% rename from sites/en/learn-to-code/img/truthiness.png rename to sites/learn-to-code/img/truthiness.png diff --git a/sites/en/learn-to-code/img/warehouse.jpg b/sites/learn-to-code/img/warehouse.jpg similarity index 100% rename from sites/en/learn-to-code/img/warehouse.jpg rename to sites/learn-to-code/img/warehouse.jpg diff --git a/sites/en/learn-to-code/img/wargames-terminal.jpg b/sites/learn-to-code/img/wargames-terminal.jpg similarity index 100% rename from sites/en/learn-to-code/img/wargames-terminal.jpg rename to sites/learn-to-code/img/wargames-terminal.jpg diff --git a/sites/en/learn-to-code/input_and_output.md b/sites/learn-to-code/input_and_output.md similarity index 100% rename from sites/en/learn-to-code/input_and_output.md rename to sites/learn-to-code/input_and_output.md diff --git a/sites/en/learn-to-code/learn-to-code.md b/sites/learn-to-code/learn-to-code.md similarity index 100% rename from sites/en/learn-to-code/learn-to-code.md rename to sites/learn-to-code/learn-to-code.md diff --git a/sites/en/learn-to-code/logic.md b/sites/learn-to-code/logic.md similarity index 100% rename from sites/en/learn-to-code/logic.md rename to sites/learn-to-code/logic.md diff --git a/sites/en/learn-to-code/loops.md b/sites/learn-to-code/loops.md similarity index 100% rename from sites/en/learn-to-code/loops.md rename to sites/learn-to-code/loops.md diff --git a/sites/en/learn-to-code/methods.md b/sites/learn-to-code/methods.md similarity index 100% rename from sites/en/learn-to-code/methods.md rename to sites/learn-to-code/methods.md diff --git a/sites/en/learn-to-code/next_steps.md b/sites/learn-to-code/next_steps.md similarity index 100% rename from sites/en/learn-to-code/next_steps.md rename to sites/learn-to-code/next_steps.md diff --git a/sites/en/learn-to-code/nil.md b/sites/learn-to-code/nil.md similarity index 100% rename from sites/en/learn-to-code/nil.md rename to sites/learn-to-code/nil.md diff --git a/sites/en/learn-to-code/numbers.md b/sites/learn-to-code/numbers.md similarity index 100% rename from sites/en/learn-to-code/numbers.md rename to sites/learn-to-code/numbers.md diff --git a/sites/en/learn-to-code/objects.md b/sites/learn-to-code/objects.md similarity index 100% rename from sites/en/learn-to-code/objects.md rename to sites/learn-to-code/objects.md diff --git a/sites/en/learn-to-code/sinatra.md b/sites/learn-to-code/sinatra.md similarity index 100% rename from sites/en/learn-to-code/sinatra.md rename to sites/learn-to-code/sinatra.md diff --git a/sites/en/learn-to-code/strings.md b/sites/learn-to-code/strings.md similarity index 100% rename from sites/en/learn-to-code/strings.md rename to sites/learn-to-code/strings.md diff --git a/sites/en/learn-to-code/the_command_line.md b/sites/learn-to-code/the_command_line.md similarity index 100% rename from sites/en/learn-to-code/the_command_line.md rename to sites/learn-to-code/the_command_line.md diff --git a/sites/en/learn-to-code/todo-learntocode.md b/sites/learn-to-code/todo-learntocode.md similarity index 100% rename from sites/en/learn-to-code/todo-learntocode.md rename to sites/learn-to-code/todo-learntocode.md diff --git a/sites/en/learn-to-code/variables.md b/sites/learn-to-code/variables.md similarity index 100% rename from sites/en/learn-to-code/variables.md rename to sites/learn-to-code/variables.md diff --git a/sites/en/message-board/add_other_features_of_your_choosing.step b/sites/message-board/add_other_features_of_your_choosing.step similarity index 100% rename from sites/en/message-board/add_other_features_of_your_choosing.step rename to sites/message-board/add_other_features_of_your_choosing.step diff --git a/sites/en/message-board/add_pages_to_create_and_look_at_individual_posts.step b/sites/message-board/add_pages_to_create_and_look_at_individual_posts.step similarity index 100% rename from sites/en/message-board/add_pages_to_create_and_look_at_individual_posts.step rename to sites/message-board/add_pages_to_create_and_look_at_individual_posts.step diff --git a/sites/en/message-board/add_replying.step b/sites/message-board/add_replying.step similarity index 100% rename from sites/en/message-board/add_replying.step rename to sites/message-board/add_replying.step diff --git a/sites/en/message-board/commands.md b/sites/message-board/commands.md similarity index 100% rename from sites/en/message-board/commands.md rename to sites/message-board/commands.md diff --git a/sites/en/message-board/create_a_new_rails_app_with_a_static_home_page.step b/sites/message-board/create_a_new_rails_app_with_a_static_home_page.step similarity index 100% rename from sites/en/message-board/create_a_new_rails_app_with_a_static_home_page.step rename to sites/message-board/create_a_new_rails_app_with_a_static_home_page.step diff --git a/sites/en/message-board/creating_a_new_controller.md b/sites/message-board/creating_a_new_controller.md similarity index 100% rename from sites/en/message-board/creating_a_new_controller.md rename to sites/message-board/creating_a_new_controller.md diff --git a/sites/en/message-board/img/create_post.png b/sites/message-board/img/create_post.png similarity index 100% rename from sites/en/message-board/img/create_post.png rename to sites/message-board/img/create_post.png diff --git a/sites/en/message-board/img/create_reply.png b/sites/message-board/img/create_reply.png similarity index 100% rename from sites/en/message-board/img/create_reply.png rename to sites/message-board/img/create_reply.png diff --git a/sites/en/message-board/img/header.png b/sites/message-board/img/header.png similarity index 100% rename from sites/en/message-board/img/header.png rename to sites/message-board/img/header.png diff --git a/sites/en/message-board/img/inline_reply.png b/sites/message-board/img/inline_reply.png similarity index 100% rename from sites/en/message-board/img/inline_reply.png rename to sites/message-board/img/inline_reply.png diff --git a/sites/en/message-board/img/post_index.png b/sites/message-board/img/post_index.png similarity index 100% rename from sites/en/message-board/img/post_index.png rename to sites/message-board/img/post_index.png diff --git a/sites/en/message-board/img/request-cycle.jpg b/sites/message-board/img/request-cycle.jpg similarity index 100% rename from sites/en/message-board/img/request-cycle.jpg rename to sites/message-board/img/request-cycle.jpg diff --git a/sites/en/message-board/img/show_post.png b/sites/message-board/img/show_post.png similarity index 100% rename from sites/en/message-board/img/show_post.png rename to sites/message-board/img/show_post.png diff --git a/sites/en/message-board/img/show_replies.png b/sites/message-board/img/show_replies.png similarity index 100% rename from sites/en/message-board/img/show_replies.png rename to sites/message-board/img/show_replies.png diff --git a/sites/en/message-board/img/static_home_page.png b/sites/message-board/img/static_home_page.png similarity index 100% rename from sites/en/message-board/img/static_home_page.png rename to sites/message-board/img/static_home_page.png diff --git a/sites/en/message-board/inline_replying_on_a_post.step b/sites/message-board/inline_replying_on_a_post.step similarity index 100% rename from sites/en/message-board/inline_replying_on_a_post.step rename to sites/message-board/inline_replying_on_a_post.step diff --git a/sites/en/message-board/install_devise.step b/sites/message-board/install_devise.step similarity index 100% rename from sites/en/message-board/install_devise.step rename to sites/message-board/install_devise.step diff --git a/sites/en/message-board/make_a_posts_index_page.step b/sites/message-board/make_a_posts_index_page.step similarity index 100% rename from sites/en/message-board/make_a_posts_index_page.step rename to sites/message-board/make_a_posts_index_page.step diff --git a/sites/en/message-board/make_it_pretty_with_bootstrap.step b/sites/message-board/make_it_pretty_with_bootstrap.step similarity index 100% rename from sites/en/message-board/make_it_pretty_with_bootstrap.step rename to sites/message-board/make_it_pretty_with_bootstrap.step diff --git a/sites/en/message-board/message-board.step b/sites/message-board/message-board.step similarity index 100% rename from sites/en/message-board/message-board.step rename to sites/message-board/message-board.step diff --git a/sites/en/message-board/mvc_overview.md b/sites/message-board/mvc_overview.md similarity index 100% rename from sites/en/message-board/mvc_overview.md rename to sites/message-board/mvc_overview.md diff --git a/sites/en/message-board/the_request_cycle.md b/sites/message-board/the_request_cycle.md similarity index 100% rename from sites/en/message-board/the_request_cycle.md rename to sites/message-board/the_request_cycle.md diff --git a/sites/en/ruby/arrays.step b/sites/ruby/arrays.step similarity index 100% rename from sites/en/ruby/arrays.step rename to sites/ruby/arrays.step diff --git a/sites/en/ruby/booleans.step b/sites/ruby/booleans.step similarity index 100% rename from sites/en/ruby/booleans.step rename to sites/ruby/booleans.step diff --git a/sites/en/ruby/classes.step b/sites/ruby/classes.step similarity index 100% rename from sites/en/ruby/classes.step rename to sites/ruby/classes.step diff --git a/sites/en/ruby/command_line.step b/sites/ruby/command_line.step similarity index 100% rename from sites/en/ruby/command_line.step rename to sites/ruby/command_line.step diff --git a/sites/en/ruby/conditionals.step b/sites/ruby/conditionals.step similarity index 100% rename from sites/en/ruby/conditionals.step rename to sites/ruby/conditionals.step diff --git a/sites/en/ruby/datatypes.step b/sites/ruby/datatypes.step similarity index 100% rename from sites/en/ruby/datatypes.step rename to sites/ruby/datatypes.step diff --git a/sites/en/ruby/functions.step b/sites/ruby/functions.step similarity index 100% rename from sites/en/ruby/functions.step rename to sites/ruby/functions.step diff --git a/sites/en/ruby/hashes.step b/sites/ruby/hashes.step similarity index 100% rename from sites/en/ruby/hashes.step rename to sites/ruby/hashes.step diff --git a/sites/en/ruby/how_to_write_a_program.step b/sites/ruby/how_to_write_a_program.step similarity index 100% rename from sites/en/ruby/how_to_write_a_program.step rename to sites/ruby/how_to_write_a_program.step diff --git a/sites/en/ruby/input_and_output.step b/sites/ruby/input_and_output.step similarity index 100% rename from sites/en/ruby/input_and_output.step rename to sites/ruby/input_and_output.step diff --git a/sites/en/ruby/irb.step b/sites/ruby/irb.step similarity index 100% rename from sites/en/ruby/irb.step rename to sites/ruby/irb.step diff --git a/sites/en/ruby/loops.step b/sites/ruby/loops.step similarity index 100% rename from sites/en/ruby/loops.step rename to sites/ruby/loops.step diff --git a/sites/en/ruby/nil.step b/sites/ruby/nil.step similarity index 100% rename from sites/en/ruby/nil.step rename to sites/ruby/nil.step diff --git a/sites/en/ruby/numbers_and_arithmetic.step b/sites/ruby/numbers_and_arithmetic.step similarity index 100% rename from sites/en/ruby/numbers_and_arithmetic.step rename to sites/ruby/numbers_and_arithmetic.step diff --git a/sites/en/ruby/overview:_building_blocks.step b/sites/ruby/overview:_building_blocks.step similarity index 100% rename from sites/en/ruby/overview:_building_blocks.step rename to sites/ruby/overview:_building_blocks.step diff --git a/sites/en/ruby/overview:_organizing.step b/sites/ruby/overview:_organizing.step similarity index 100% rename from sites/en/ruby/overview:_organizing.step rename to sites/ruby/overview:_organizing.step diff --git a/sites/en/ruby/ruby.step b/sites/ruby/ruby.step similarity index 100% rename from sites/en/ruby/ruby.step rename to sites/ruby/ruby.step diff --git a/sites/en/ruby/running_programs_from_a_file.step b/sites/ruby/running_programs_from_a_file.step similarity index 100% rename from sites/en/ruby/running_programs_from_a_file.step rename to sites/ruby/running_programs_from_a_file.step diff --git a/sites/en/ruby/strings.step b/sites/ruby/strings.step similarity index 100% rename from sites/en/ruby/strings.step rename to sites/ruby/strings.step diff --git a/sites/en/ruby/summary:_basics.step b/sites/ruby/summary:_basics.step similarity index 100% rename from sites/en/ruby/summary:_basics.step rename to sites/ruby/summary:_basics.step diff --git a/sites/en/ruby/summary:_tools.step b/sites/ruby/summary:_tools.step similarity index 100% rename from sites/en/ruby/summary:_tools.step rename to sites/ruby/summary:_tools.step diff --git a/sites/en/ruby/symbols.step b/sites/ruby/symbols.step similarity index 100% rename from sites/en/ruby/symbols.step rename to sites/ruby/symbols.step diff --git a/sites/en/ruby/using_virtual_machines.step b/sites/ruby/using_virtual_machines.step similarity index 100% rename from sites/en/ruby/using_virtual_machines.step rename to sites/ruby/using_virtual_machines.step diff --git a/sites/en/ruby/variables.step b/sites/ruby/variables.step similarity index 100% rename from sites/en/ruby/variables.step rename to sites/ruby/variables.step diff --git a/sites/en/ruby/what_is_ruby.step b/sites/ruby/what_is_ruby.step similarity index 100% rename from sites/en/ruby/what_is_ruby.step rename to sites/ruby/what_is_ruby.step diff --git a/sites/en/ruby/working_with_collections.step b/sites/ruby/working_with_collections.step similarity index 100% rename from sites/en/ruby/working_with_collections.step rename to sites/ruby/working_with_collections.step diff --git a/sites/en/testing-rails-applications/additional_concepts.step b/sites/testing-rails-applications/additional_concepts.step similarity index 100% rename from sites/en/testing-rails-applications/additional_concepts.step rename to sites/testing-rails-applications/additional_concepts.step diff --git a/sites/en/testing-rails-applications/final_challenge.step b/sites/testing-rails-applications/final_challenge.step similarity index 100% rename from sites/en/testing-rails-applications/final_challenge.step rename to sites/testing-rails-applications/final_challenge.step diff --git a/sites/en/testing-rails-applications/img/rails-test-types.png b/sites/testing-rails-applications/img/rails-test-types.png similarity index 100% rename from sites/en/testing-rails-applications/img/rails-test-types.png rename to sites/testing-rails-applications/img/rails-test-types.png diff --git a/sites/en/testing-rails-applications/testing-rails-applications.step b/sites/testing-rails-applications/testing-rails-applications.step similarity index 100% rename from sites/en/testing-rails-applications/testing-rails-applications.step rename to sites/testing-rails-applications/testing-rails-applications.step diff --git a/sites/en/testing-rails-applications/testing_frameworks.step b/sites/testing-rails-applications/testing_frameworks.step similarity index 100% rename from sites/en/testing-rails-applications/testing_frameworks.step rename to sites/testing-rails-applications/testing_frameworks.step diff --git a/sites/en/testing-rails-applications/types_of_tests.step b/sites/testing-rails-applications/types_of_tests.step similarity index 100% rename from sites/en/testing-rails-applications/types_of_tests.step rename to sites/testing-rails-applications/types_of_tests.step diff --git a/sites/en/testing-rails-applications/what_are_tests.step b/sites/testing-rails-applications/what_are_tests.step similarity index 100% rename from sites/en/testing-rails-applications/what_are_tests.step rename to sites/testing-rails-applications/what_are_tests.step diff --git a/sites/en/workshop/activities.md b/sites/workshop/activities.md similarity index 100% rename from sites/en/workshop/activities.md rename to sites/workshop/activities.md diff --git a/sites/en/workshop/beginners.mw b/sites/workshop/beginners.mw similarity index 100% rename from sites/en/workshop/beginners.mw rename to sites/workshop/beginners.mw diff --git a/sites/en/workshop/closing.deck.md b/sites/workshop/closing.deck.md similarity index 100% rename from sites/en/workshop/closing.deck.md rename to sites/workshop/closing.deck.md diff --git a/sites/en/workshop/command_prompt.mw b/sites/workshop/command_prompt.mw similarity index 100% rename from sites/en/workshop/command_prompt.mw rename to sites/workshop/command_prompt.mw diff --git a/sites/en/workshop/diagrams.mw b/sites/workshop/diagrams.mw similarity index 100% rename from sites/en/workshop/diagrams.mw rename to sites/workshop/diagrams.mw diff --git a/sites/en/workshop/foundational_skills.deck.md b/sites/workshop/foundational_skills.deck.md similarity index 100% rename from sites/en/workshop/foundational_skills.deck.md rename to sites/workshop/foundational_skills.deck.md diff --git a/sites/en/workshop/helpful_examples.mw b/sites/workshop/helpful_examples.mw similarity index 100% rename from sites/en/workshop/helpful_examples.mw rename to sites/workshop/helpful_examples.mw diff --git a/sites/en/workshop/img/Win7_search_programs.jpg b/sites/workshop/img/Win7_search_programs.jpg similarity index 100% rename from sites/en/workshop/img/Win7_search_programs.jpg rename to sites/workshop/img/Win7_search_programs.jpg diff --git a/sites/en/workshop/img/acrobat.jpg b/sites/workshop/img/acrobat.jpg similarity index 100% rename from sites/en/workshop/img/acrobat.jpg rename to sites/workshop/img/acrobat.jpg diff --git a/sites/en/workshop/img/agile.jpg b/sites/workshop/img/agile.jpg similarity index 100% rename from sites/en/workshop/img/agile.jpg rename to sites/workshop/img/agile.jpg diff --git a/sites/en/workshop/img/cheatsheet.png b/sites/workshop/img/cheatsheet.png similarity index 100% rename from sites/en/workshop/img/cheatsheet.png rename to sites/workshop/img/cheatsheet.png diff --git a/sites/en/workshop/img/ey_logo_rgb.png b/sites/workshop/img/ey_logo_rgb.png similarity index 100% rename from sites/en/workshop/img/ey_logo_rgb.png rename to sites/workshop/img/ey_logo_rgb.png diff --git a/sites/en/workshop/img/firefox.png b/sites/workshop/img/firefox.png similarity index 100% rename from sites/en/workshop/img/firefox.png rename to sites/workshop/img/firefox.png diff --git a/sites/en/workshop/img/git.png b/sites/workshop/img/git.png similarity index 100% rename from sites/en/workshop/img/git.png rename to sites/workshop/img/git.png diff --git a/sites/en/workshop/img/git_bash.png b/sites/workshop/img/git_bash.png similarity index 100% rename from sites/en/workshop/img/git_bash.png rename to sites/workshop/img/git_bash.png diff --git a/sites/en/workshop/img/itunes.png b/sites/workshop/img/itunes.png similarity index 100% rename from sites/en/workshop/img/itunes.png rename to sites/workshop/img/itunes.png diff --git a/sites/en/workshop/img/linux_logo.gif b/sites/workshop/img/linux_logo.gif similarity index 100% rename from sites/en/workshop/img/linux_logo.gif rename to sites/workshop/img/linux_logo.gif diff --git a/sites/en/workshop/img/mac_terminal_sm.png b/sites/workshop/img/mac_terminal_sm.png similarity index 100% rename from sites/en/workshop/img/mac_terminal_sm.png rename to sites/workshop/img/mac_terminal_sm.png diff --git a/sites/en/workshop/img/os_x_logo.jpg b/sites/workshop/img/os_x_logo.jpg similarity index 100% rename from sites/en/workshop/img/os_x_logo.jpg rename to sites/workshop/img/os_x_logo.jpg diff --git a/sites/en/workshop/img/rails_logo.jpg b/sites/workshop/img/rails_logo.jpg similarity index 100% rename from sites/en/workshop/img/rails_logo.jpg rename to sites/workshop/img/rails_logo.jpg diff --git a/sites/en/workshop/img/railsbridge_logo.png b/sites/workshop/img/railsbridge_logo.png similarity index 100% rename from sites/en/workshop/img/railsbridge_logo.png rename to sites/workshop/img/railsbridge_logo.png diff --git a/sites/en/workshop/img/ruby-logo.jpg b/sites/workshop/img/ruby-logo.jpg similarity index 100% rename from sites/en/workshop/img/ruby-logo.jpg rename to sites/workshop/img/ruby-logo.jpg diff --git a/sites/en/workshop/img/rubygems.png b/sites/workshop/img/rubygems.png similarity index 100% rename from sites/en/workshop/img/rubygems.png rename to sites/workshop/img/rubygems.png diff --git a/sites/en/workshop/img/windows_logo.gif b/sites/workshop/img/windows_logo.gif similarity index 100% rename from sites/en/workshop/img/windows_logo.gif rename to sites/workshop/img/windows_logo.gif diff --git a/sites/en/workshop/img/wordpress.jpg b/sites/workshop/img/wordpress.jpg similarity index 100% rename from sites/en/workshop/img/wordpress.jpg rename to sites/workshop/img/wordpress.jpg diff --git a/sites/en/workshop/more_teacher_training.deck.md b/sites/workshop/more_teacher_training.deck.md similarity index 100% rename from sites/en/workshop/more_teacher_training.deck.md rename to sites/workshop/more_teacher_training.deck.md diff --git a/sites/en/workshop/more_teacher_training_2016.deck.md b/sites/workshop/more_teacher_training_2016.deck.md similarity index 100% rename from sites/en/workshop/more_teacher_training_2016.deck.md rename to sites/workshop/more_teacher_training_2016.deck.md diff --git a/sites/en/workshop/noobie-outline.txt b/sites/workshop/noobie-outline.txt similarity index 100% rename from sites/en/workshop/noobie-outline.txt rename to sites/workshop/noobie-outline.txt diff --git a/sites/en/workshop/resources.md b/sites/workshop/resources.md similarity index 100% rename from sites/en/workshop/resources.md rename to sites/workshop/resources.md diff --git a/sites/en/workshop/ruby_for_beginners.deck.md b/sites/workshop/ruby_for_beginners.deck.md similarity index 100% rename from sites/en/workshop/ruby_for_beginners.deck.md rename to sites/workshop/ruby_for_beginners.deck.md diff --git a/sites/en/workshop/ruby_for_programmers.deck.md b/sites/workshop/ruby_for_programmers.deck.md similarity index 100% rename from sites/en/workshop/ruby_for_programmers.deck.md rename to sites/workshop/ruby_for_programmers.deck.md diff --git a/sites/en/workshop/ta_cheat_sheet.md b/sites/workshop/ta_cheat_sheet.md similarity index 100% rename from sites/en/workshop/ta_cheat_sheet.md rename to sites/workshop/ta_cheat_sheet.md diff --git a/sites/en/workshop/teacher_cheat_sheet.md b/sites/workshop/teacher_cheat_sheet.md similarity index 100% rename from sites/en/workshop/teacher_cheat_sheet.md rename to sites/workshop/teacher_cheat_sheet.md diff --git a/sites/en/workshop/teaching_tips.md b/sites/workshop/teaching_tips.md similarity index 100% rename from sites/en/workshop/teaching_tips.md rename to sites/workshop/teaching_tips.md diff --git a/sites/en/workshop/topics.md b/sites/workshop/topics.md similarity index 100% rename from sites/en/workshop/topics.md rename to sites/workshop/topics.md diff --git a/sites/en/workshop/web_apps.deck.md b/sites/workshop/web_apps.deck.md similarity index 100% rename from sites/en/workshop/web_apps.deck.md rename to sites/workshop/web_apps.deck.md diff --git a/sites/en/workshop/welcome.deck.md b/sites/workshop/welcome.deck.md similarity index 100% rename from sites/en/workshop/welcome.deck.md rename to sites/workshop/welcome.deck.md diff --git a/sites/en/workshop/workshop.md b/sites/workshop/workshop.md similarity index 100% rename from sites/en/workshop/workshop.md rename to sites/workshop/workshop.md diff --git a/sites/zh-tw/nihao/nihao.step b/sites/zh-tw/nihao/nihao.step deleted file mode 100644 index 76a2c10f7..000000000 --- a/sites/zh-tw/nihao/nihao.step +++ /dev/null @@ -1 +0,0 @@ -message "世界你好!" diff --git a/spec/site_spec.rb b/spec/site_spec.rb index 2675b0677..148971725 100644 --- a/spec/site_spec.rb +++ b/spec/site_spec.rb @@ -9,18 +9,14 @@ site_names.should include("installfest") site_names.should include("intro-to-rails") end - + it "has doc files" do installfest = Site.named("installfest") doc_filenames = installfest.docs.map(&:filename) doc_filenames.should include("configure_git.step") end - + it "finds the sites_dir" do Site.sites_dir.should == File.expand_path(File.join(File.dirname(__FILE__), "..", "sites", "en")) end - - it "finds the sites_dir for Spanish locale" do - Site.sites_dir('es').should == File.expand_path(File.join(File.dirname(__FILE__), "..", "sites", "es")) - end end From a1f772039a6c7b62e4548fb7682f64f618fcc3be Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 10:39:46 -0500 Subject: [PATCH 18/35] Create constant --- app.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app.rb b/app.rb index bce4ace91..314cdba43 100755 --- a/app.rb +++ b/app.rb @@ -32,6 +32,7 @@ class InstallFest < Sinatra::Application # Set available locales in Array of Strings; this is also used when # checking availability in dynamic locale assignment, they must be strings. AVAILABLE_LOCALES = %i[en es zh-tw].freeze + DEFAULT_SITE = "docs" set :assets, Sprockets::Environment.new settings.assets.append_path 'assets/stylesheets' @@ -70,7 +71,7 @@ def default_site if host && sites.include?(site = subdomain) site else - 'docs' + DEFAULT_SITE end end From 8b938ca69f41d8b4b1c18dfd04b5f7e3d6b5390e Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 10:39:57 -0500 Subject: [PATCH 19/35] Make conditional multiline --- app.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app.rb b/app.rb index 314cdba43..cd76b5862 100755 --- a/app.rb +++ b/app.rb @@ -113,7 +113,9 @@ def redirect_pages after '/:site/*' do # Any real page (starts with a site and doesn't end with an extension) # gets saved as the 'back' for the next pageload. - cookies[:docs_back_path] = request.fullpath if sites.include?(params[:site]) && !request.fullpath.match(/\..+\z/) + if sites.include?(params[:site]) && !request.fullpath.match(/\..+\z/) + cookies[:docs_back_path] = request.fullpath + end end def dynamic_locale From 9aaba0a53931ae3a7741a7d13c833e36d003270a Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 10:51:12 -0500 Subject: [PATCH 20/35] Revert style changes --- app.rb | 89 +++++++++++++++++++++++++++-------------------------- lib/site.rb | 12 ++++---- 2 files changed, 51 insertions(+), 50 deletions(-) diff --git a/app.rb b/app.rb index cd76b5862..0a6495a23 100755 --- a/app.rb +++ b/app.rb @@ -9,24 +9,23 @@ require 'zip' require 'tmpdir' -here = __dir__ +here = File.expand_path File.dirname(__FILE__) lib = File.expand_path "#{here}/lib" $: << lib -require 'doc_page' -require 'step_page' -require 'markdown_page' -require 'media_wiki_page' -require 'raw_page' -require 'deck' -require 'deck/rack_app' -require 'titleizer' -require 'site' -require 'sprockets' -require 'jquery-cdn' - -class InstallFest < Sinatra::Application - # TODO: use Sinatra::Base instead, with more explicit config +require "doc_page" +require "step_page" +require "markdown_page" +require "media_wiki_page" +require "raw_page" +require "deck" +require "deck/rack_app" +require "titleizer" +require "site" +require "sprockets" +require "jquery-cdn" + +class InstallFest < Sinatra::Application # TODO: use Sinatra::Base instead, with more explicit config include Erector::Mixin # Set available locales in Array of Strings; this is also used when @@ -35,13 +34,15 @@ class InstallFest < Sinatra::Application DEFAULT_SITE = "docs" set :assets, Sprockets::Environment.new - settings.assets.append_path 'assets/stylesheets' - settings.assets.append_path 'assets/javascripts' - settings.assets.append_path 'public/fonts' + settings.assets.append_path "assets/stylesheets" + settings.assets.append_path "assets/javascripts" + settings.assets.append_path "public/fonts" settings.assets.append_path Bootstrap.javascripts_path JqueryCdn.install(settings.assets) - set :cookie_options, domain: nil if settings.environment == :development + if settings.environment == :development + set :cookie_options, domain: nil + end configure do I18n::Backend::Simple.include(I18n::Backend::Fallbacks) @@ -55,16 +56,16 @@ class InstallFest < Sinatra::Application def initialize super - @here = __dir__ + @here = File.expand_path(File.dirname(__FILE__)) end attr_reader :here attr_writer :default_site - # TODO: test + # todo: test # returns the most-specific hostname component, e.g. "foo" for "foo.example.com" def subdomain - host.split('.').first + host.split(".").first end def default_site @@ -76,7 +77,7 @@ def default_site end def host - request&.host + request && request.host end def site_dir @@ -170,16 +171,16 @@ def render_page case ext - when 'deck.md', 'deck' + when "deck.md", "deck" render_deck - when 'md' + when "md" MarkdownPage.new(options).to_html - when 'mw' + when "mw" MediaWikiPage.new(options).to_html - when 'step' + when "step" StepPage.new(options).to_html else @@ -197,18 +198,18 @@ def render_page def render_deck slides = Deck::Slide.split(src) - Deck::SlideDeck.new(slides: slides).to_pretty + Deck::SlideDeck.new(:slides => slides).to_pretty end before do expires 3600, :public end - get '/favicon.ico' do + get "/favicon.ico" do halt 404 end - get '/assets/:file.:ext' do + get "/assets/:file.:ext" do mime_type = { 'js' => 'application/javascript', 'css' => 'text/css', @@ -219,16 +220,16 @@ def render_deck settings.assets["#{params[:file]}.#{params[:ext]}"] end - get '/fonts/font-awesome/:file' do + get "/fonts/font-awesome/:file" do font_path = File.join(FontAwesome::Sass.gem_path, 'assets', 'fonts', 'font-awesome', params[:file]) send_file font_path end - get '/' do + get "/" do redirect "/#{default_site}/" end - get '/:site/:name/src' do + get "/:site/:name/src" do RawPage.new( site: Site.named(params[:site], I18n.locale), page_name: params[:name], @@ -242,9 +243,9 @@ def render_deck halt 404 end - get '/:site/:name.zip' do + get "/:site/:name.zip" do manifest_path = "#{site_dir}/#{params[:name]}.zip-manifest" - if File.exist?(manifest_path) + if File.exists?(manifest_path) manifest_files = File.read(manifest_path).split("\n") zip_path = File.join(Dir.tmpdir, "#{params[:name]}.zip") FileUtils.rm_rf(zip_path) @@ -260,9 +261,9 @@ def render_deck end end - get '/:site/:name.:ext' do + get "/:site/:name.:ext" do if sites.include?(params[:site]) - if params[:ext] == 'deck' # to show a markdown page as slides, change the ".md" to ".deck" + if params[:ext] == "deck" # to show a markdown page as slides, change the ".md" to ".deck" render_deck else send_file "#{site_dir}/#{params[:name]}.#{params[:ext]}" @@ -270,16 +271,16 @@ def render_deck end end - get '/:site/:subdir/:name.:ext' do + get "/:site/:subdir/:name.:ext" do send_file "#{site_dir}/#{params[:subdir]}/#{params[:name]}.#{params[:ext]}" if sites.include?(params[:site]) end - get '/:site/:name/' do + get "/:site/:name/" do # remove any extraneous slash from otherwise well-formed page URLs redirect request.fullpath.chomp('/') end - get '/:site/:name' do + get "/:site/:name" do site_name = params[:site] if redirect_sites[site_name] redirect "#{redirect_sites[site_name]}/#{params[:name]}" @@ -294,22 +295,22 @@ def render_deck end end - get '/:site/:name/:section/' do + get "/:site/:name/:section/" do # remove any extraneous slash from otherwise well-formed page URLs redirect request.fullpath.chomp('/') end - get '/:site/:name/:section' do + get "/:site/:name/:section" do render_page end - get '/:site' do + get "/:site" do # add a slash to any URLs that contain only a site # (otherwise paths in that site's pages would resolve relative to the root) redirect "#{request.fullpath}/" end - get '/:site/' do + get "/:site/" do site_name = params[:site] if redirect_sites[site_name] redirect "#{redirect_sites[site_name]}/" diff --git a/lib/site.rb b/lib/site.rb index e40b0fbce..cd4fc4008 100644 --- a/lib/site.rb +++ b/lib/site.rb @@ -1,7 +1,7 @@ class Site - DOC_TYPES = %w[step md deck.md mw].freeze + DOC_TYPES = %w{step md deck.md mw} - @@here = __dir__ + @@here = File.expand_path(File.dirname(__FILE__)) @@project_root = File.dirname(@@here) def self.sites_dir @@ -12,7 +12,7 @@ def self.all Dir[File.join(sites_dir, '*')].map { |dir| Site.new(dir) } end - def self.named(name) + def self.named name site = all.detect { |folder| folder.name == name } raise "No site found with the name '#{name}'" unless site @@ -21,7 +21,7 @@ def self.named(name) attr_reader :dir - def initialize(dir) + def initialize dir @dir = dir end @@ -31,13 +31,13 @@ def name def docs file_path_glob = File.join(@dir, "*.{#{DOC_TYPES.join(',')}}") - Dir[file_path_glob].map { |path| Doc.new(path) } + Dir[file_path_glob].map{|path| Doc.new(path)} end class Doc attr_reader :path - def initialize(path) + def initialize path @path = path end From 4c5eb7865ab5b2ca2dc4f54c8a3f7d17949b39dd Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 10:54:38 -0500 Subject: [PATCH 21/35] Revert style changes --- app.rb | 65 ++++++++++++++++++++++++++++++++++++---------------------- 1 file changed, 40 insertions(+), 25 deletions(-) diff --git a/app.rb b/app.rb index 0a6495a23..511670998 100755 --- a/app.rb +++ b/app.rb @@ -159,32 +159,34 @@ def back_path end def render_page - options = { - site: Site.named(params[:site]), - page_name: params[:name], - doc_title: Titleizer.title_for_page(params[:name]), - doc_path: doc_path, - back: back_path, - src: src, - locale: I18n.locale - } - - case ext - - when "deck.md", "deck" - render_deck + begin + options = { + site: Site.named(params[:site]), + page_name: params[:name], + doc_title: Titleizer.title_for_page(params[:name]), + doc_path: doc_path, + back: back_path, + src: src, + locale: I18n.locale + } + + case ext + + when "deck.md", "deck" + render_deck - when "md" - MarkdownPage.new(options).to_html + when "md" + MarkdownPage.new(options).to_html - when "mw" - MediaWikiPage.new(options).to_html + when "mw" + MediaWikiPage.new(options).to_html - when "step" - StepPage.new(options).to_html + when "step" + StepPage.new(options).to_html - else - raise "unknown file type #{doc_path}" + else + raise "unknown file type #{doc_path}" + end end rescue Errno::ENOENT => e p e @@ -205,7 +207,7 @@ def render_deck expires 3600, :public end - get "/favicon.ico" do + get '/favicon.ico' do halt 404 end @@ -220,7 +222,7 @@ def render_deck settings.assets["#{params[:file]}.#{params[:ext]}"] end - get "/fonts/font-awesome/:file" do + get '/fonts/font-awesome/:file' do font_path = File.join(FontAwesome::Sass.gem_path, 'assets', 'fonts', 'font-awesome', params[:file]) send_file font_path end @@ -230,6 +232,19 @@ def render_deck end get "/:site/:name/src" do + begin + RawPage.new( + site: Site.named(params[:site], I18n.locale), + page_name: params[:name], + doc_title: File.basename(doc_path), + doc_path: doc_path, + src: src, + locale: I18n.locale, + ).to_html + rescue Errno::ENOENT => e + p e + halt 404 + end RawPage.new( site: Site.named(params[:site], I18n.locale), page_name: params[:name], @@ -263,7 +278,7 @@ def render_deck get "/:site/:name.:ext" do if sites.include?(params[:site]) - if params[:ext] == "deck" # to show a markdown page as slides, change the ".md" to ".deck" + if params[:ext] == "deck" # to show a markdown page as slides, change the ".md" to ".deck" render_deck else send_file "#{site_dir}/#{params[:name]}.#{params[:ext]}" From 6381517f2e5363d07837ec0ad411d1e3dd84a958 Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 11:00:02 -0500 Subject: [PATCH 22/35] Revert style changes --- app.rb | 49 ++++++++++++++++++++----------------------------- 1 file changed, 20 insertions(+), 29 deletions(-) diff --git a/app.rb b/app.rb index 511670998..da7ca7787 100755 --- a/app.rb +++ b/app.rb @@ -22,10 +22,10 @@ require "deck/rack_app" require "titleizer" require "site" -require "sprockets" -require "jquery-cdn" +require 'sprockets' +require 'jquery-cdn' -class InstallFest < Sinatra::Application # TODO: use Sinatra::Base instead, with more explicit config +class InstallFest < Sinatra::Application # todo: use Sinatra::Base instead, with more explicit config include Erector::Mixin # Set available locales in Array of Strings; this is also used when @@ -106,9 +106,11 @@ def redirect_pages end before do - I18n.locale = dynamic_locale - rescue I18n::InvalidLocale - I18n.locale = I18n.default_locale + begin + I18n.locale = dynamic_locale + rescue I18n::InvalidLocale + I18n.locale = I18n.default_locale + end end after '/:site/*' do @@ -130,7 +132,7 @@ def src end def ext - Regexp.last_match(1) if doc_path.match(/\.(.*)/) + $1 if doc_path.match(/\.(.*)/) end def doc_path @@ -167,25 +169,25 @@ def render_page doc_path: doc_path, back: back_path, src: src, - locale: I18n.locale + locale: I18n.locale, } case ext - when "deck.md", "deck" - render_deck + when "deck.md", "deck" + render_deck - when "md" - MarkdownPage.new(options).to_html + when "md" + MarkdownPage.new(options).to_html - when "mw" - MediaWikiPage.new(options).to_html + when "mw" + MediaWikiPage.new(options).to_html - when "step" - StepPage.new(options).to_html + when "step" + StepPage.new(options).to_html - else - raise "unknown file type #{doc_path}" + else + raise "unknown file type #{doc_path}" end end rescue Errno::ENOENT => e @@ -245,17 +247,6 @@ def render_deck p e halt 404 end - RawPage.new( - site: Site.named(params[:site], I18n.locale), - page_name: params[:name], - doc_title: File.basename(doc_path), - doc_path: doc_path, - src: src, - locale: I18n.locale - ).to_html - rescue Errno::ENOENT => e - p e - halt 404 end get "/:site/:name.zip" do From 239de612cc23e1f61d26545084af6adfb275bc43 Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 11:03:20 -0500 Subject: [PATCH 23/35] Revert style changes --- app.rb | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/app.rb b/app.rb index da7ca7787..736ec5d39 100755 --- a/app.rb +++ b/app.rb @@ -189,15 +189,14 @@ def render_page else raise "unknown file type #{doc_path}" end + rescue Errno::ENOENT => e + p e + e.backtrace.each do |line| + break if line =~ %r{sinatra/base.rb} + puts "\t" + line + end + halt 404 end - rescue Errno::ENOENT => e - p e - e.backtrace.each do |line| - break if line =~ %r{sinatra/base.rb} - - puts "\t" + line - end - halt 404 end def render_deck From f0863872f1e953c5080c230a7ccc6c5c848dc597 Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 11:09:52 -0500 Subject: [PATCH 24/35] Revert style changes --- app.rb | 8 +++++--- lib/site.rb | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/app.rb b/app.rb index 736ec5d39..c6f576ecf 100755 --- a/app.rb +++ b/app.rb @@ -192,8 +192,8 @@ def render_page rescue Errno::ENOENT => e p e e.backtrace.each do |line| - break if line =~ %r{sinatra/base.rb} - puts "\t" + line + break if line =~ /sinatra\/base.rb/ + puts "\t"+line end halt 404 end @@ -277,7 +277,9 @@ def render_deck end get "/:site/:subdir/:name.:ext" do - send_file "#{site_dir}/#{params[:subdir]}/#{params[:name]}.#{params[:ext]}" if sites.include?(params[:site]) + if sites.include?(params[:site]) + send_file "#{site_dir}/#{params[:subdir]}/#{params[:name]}.#{params[:ext]}" + end end get "/:site/:name/" do diff --git a/lib/site.rb b/lib/site.rb index cd4fc4008..d97d8c397 100644 --- a/lib/site.rb +++ b/lib/site.rb @@ -9,7 +9,7 @@ def self.sites_dir end def self.all - Dir[File.join(sites_dir, '*')].map { |dir| Site.new(dir) } + Dir[File.join(sites_dir, '*')].map{|dir| Site.new(dir)} end def self.named name @@ -48,5 +48,6 @@ def filename def name filename.split('.').first end + end end From fa31ff0f11c739a5bdee171bf40f037f57eae3de Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Tue, 23 Aug 2022 11:53:43 -0500 Subject: [PATCH 25/35] Update specs --- app.rb | 2 +- spec/app_spec.rb | 4 ++-- spec/contents_spec.rb | 6 +++--- spec/site_index_spec.rb | 2 +- spec/site_spec.rb | 4 ++-- spec/site_syntax_spec.rb | 2 +- spec/support/i18n_helper.rb | 7 ++++--- 7 files changed, 14 insertions(+), 13 deletions(-) diff --git a/app.rb b/app.rb index c6f576ecf..024862ca6 100755 --- a/app.rb +++ b/app.rb @@ -30,7 +30,7 @@ class InstallFest < Sinatra::Application # todo: use Sinatra::Base instead, wi # Set available locales in Array of Strings; this is also used when # checking availability in dynamic locale assignment, they must be strings. - AVAILABLE_LOCALES = %i[en es zh-tw].freeze + AVAILABLE_LOCALES = %w[en es zh-tw].freeze DEFAULT_SITE = "docs" set :assets, Sprockets::Environment.new diff --git a/spec/app_spec.rb b/spec/app_spec.rb index 4bb0ad8b7..910d7efed 100755 --- a/spec/app_spec.rb +++ b/spec/app_spec.rb @@ -100,10 +100,10 @@ def get! *args end describe "in the 'es' locale" do - it "uses the 'es' subdir as the sites_dir" do + it "uses the same subdir as the sites_dir" do get "/", locale: "es" - es_dir = File.expand_path(File.join(__FILE__, "..", "..", "sites", "es")) + es_dir = File.expand_path(File.join(__FILE__, "..", "..", "sites")) expect(true_app.sites_dir).to eq(es_dir) end diff --git a/spec/contents_spec.rb b/spec/contents_spec.rb index 7c77c50db..568fd1279 100644 --- a/spec/contents_spec.rb +++ b/spec/contents_spec.rb @@ -16,8 +16,8 @@ describe "absolute links" do let(:site_name) { 'docs' } - let(:site_dir) { "#{real_sites_dir}/en/#{site_name}" } - let(:page_name) { 'docs' } + let(:site_dir) { "#{real_sites_dir}/#{site_name}" } + let(:page_name) { 'docs' } before do @toc_html = Nokogiri.parse(@toc.to_html) end @@ -30,7 +30,7 @@ describe 'capitalization' do let(:site_name) { 'installfest' } - let(:site_dir) { "#{real_sites_dir}/en/#{site_name}" } + let(:site_dir) { "#{real_sites_dir}/#{site_name}" } let(:page_name) { 'installfest' } before do @toc_html = Nokogiri.parse(@toc.to_html) diff --git a/spec/site_index_spec.rb b/spec/site_index_spec.rb index c69dc0d1d..d25404f52 100644 --- a/spec/site_index_spec.rb +++ b/spec/site_index_spec.rb @@ -9,7 +9,7 @@ end it "lists all sites in the /sites/ directory" do - all_sites = Dir['sites/en/**'].map { |site_path| site_path.sub('sites/en/', '') } + all_sites = Dir['sites/**'].map { |site_path| site_path.sub('sites/', '') } @site_index.sites.should =~ all_sites end diff --git a/spec/site_spec.rb b/spec/site_spec.rb index 148971725..599f96cbc 100644 --- a/spec/site_spec.rb +++ b/spec/site_spec.rb @@ -16,7 +16,7 @@ doc_filenames.should include("configure_git.step") end - it "finds the sites_dir" do - Site.sites_dir.should == File.expand_path(File.join(File.dirname(__FILE__), "..", "sites", "en")) + it "finds the default sites_dir" do + Site.sites_dir.should == File.expand_path(File.join(File.dirname(__FILE__), "..", "sites")) end end diff --git a/spec/site_syntax_spec.rb b/spec/site_syntax_spec.rb index 01fdb923f..9153deed7 100644 --- a/spec/site_syntax_spec.rb +++ b/spec/site_syntax_spec.rb @@ -16,7 +16,7 @@ def app InstallFest::AVAILABLE_LOCALES.each do |locale| describe "in locale '#{locale}'" do - Site.all(locale).each do |site| + Site.all.each do |site| describe "#{site.name} pages..." do it 'uses all images in the /img folder' do site_folder = File.expand_path(File.join(here, '..', 'sites', locale, site.name)) diff --git a/spec/support/i18n_helper.rb b/spec/support/i18n_helper.rb index 33306b365..502728e6f 100644 --- a/spec/support/i18n_helper.rb +++ b/spec/support/i18n_helper.rb @@ -1,4 +1,5 @@ require 'i18n' +require_relative '../../app' module I18nHelper def setup_test_translations @@ -6,10 +7,10 @@ def setup_test_translations top = File.expand_path "#{here}/../.." I18n::Backend::Simple.include(I18n::Backend::Fallbacks) - I18n.load_path = Dir[File.join(top, 'locales', '*.yml')] + I18n.load_path = Dir[File.join(top, 'locales', '**/*.yml')] I18n.backend.load_translations - I18n.available_locales = Dir['sites/*'].map { |path| File.basename(path).to_sym } + I18n.available_locales = ::InstallFest::AVAILABLE_LOCALES I18n.locale = :en end -end \ No newline at end of file +end From 61464ebb9778caa41980e33886afa3e301d8c982 Mon Sep 17 00:00:00 2001 From: Melissa Xie Date: Mon, 21 Nov 2022 18:54:25 -0500 Subject: [PATCH 26/35] Bump Ruby version to 2.7.6 This will also allow us to upgrade our Heroku stack to the almost-latest. --- .ruby-version | 2 +- Gemfile | 2 +- Gemfile.lock | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.ruby-version b/.ruby-version index a603bb50a..49cdd668e 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.7.5 +2.7.6 diff --git a/Gemfile b/Gemfile index ab6a5ab0e..024f0872a 100644 --- a/Gemfile +++ b/Gemfile @@ -1,6 +1,6 @@ source "https://rubygems.org/" -ruby '2.7.5' +ruby '2.7.6' gem 'activesupport' gem "erector", "~> 0.10.0" diff --git a/Gemfile.lock b/Gemfile.lock index 7e0fac3b3..3a3c8dbf4 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -140,7 +140,7 @@ DEPENDENCIES thin (= 1.8.1) RUBY VERSION - ruby 2.7.5p203 + ruby 2.7.6p219 BUNDLED WITH - 2.3.8 + 2.3.26 From 3b12c7d62658eebb656953871f10d4b0f249fd59 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 22 Nov 2022 00:06:17 +0000 Subject: [PATCH 27/35] Bump sinatra and sinatra-contrib Bumps [sinatra](https://github.com/sinatra/sinatra) and [sinatra-contrib](https://github.com/sinatra/sinatra). These dependencies needed to be updated together. Updates `sinatra` from 1.4.8 to 3.0.3 - [Release notes](https://github.com/sinatra/sinatra/releases) - [Changelog](https://github.com/sinatra/sinatra/blob/master/CHANGELOG.md) - [Commits](https://github.com/sinatra/sinatra/compare/v1.4.8...v3.0.3) Updates `sinatra-contrib` from 1.4.7 to 3.0.3 - [Release notes](https://github.com/sinatra/sinatra/releases) - [Changelog](https://github.com/sinatra/sinatra/blob/master/CHANGELOG.md) - [Commits](https://github.com/sinatra/sinatra/compare/v1.4.7...v3.0.3) --- updated-dependencies: - dependency-name: sinatra dependency-type: direct:production - dependency-name: sinatra-contrib dependency-type: direct:production ... Signed-off-by: dependabot[bot] --- Gemfile | 4 ++-- Gemfile.lock | 35 +++++++++++++++++++---------------- 2 files changed, 21 insertions(+), 18 deletions(-) diff --git a/Gemfile b/Gemfile index 024f0872a..5c9605ec8 100644 --- a/Gemfile +++ b/Gemfile @@ -4,8 +4,8 @@ ruby '2.7.6' gem 'activesupport' gem "erector", "~> 0.10.0" -gem "sinatra", "~> 1.4.0" -gem "sinatra-contrib", "~> 1.4.0" +gem "sinatra", "~> 3.0.3" +gem "sinatra-contrib", "~> 3.0.3" gem "nokogiri" gem "thin", "1.8.1" gem 'rack-codehighlighter' diff --git a/Gemfile.lock b/Gemfile.lock index 3a3c8dbf4..e8c50f7af 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -44,17 +44,19 @@ GEM ruby_dep (~> 1.2) mini_portile2 (2.8.0) minitest (5.15.0) - multi_json (1.12.1) + multi_json (1.15.0) + mustermann (3.0.0) + ruby2_keywords (~> 0.0.1) nokogiri (1.13.2) mini_portile2 (~> 2.8.0) racc (~> 1.4) polyglot (0.3.5) racc (1.6.0) - rack (1.6.13) + rack (2.2.4) rack-codehighlighter (0.5.1) nokogiri (>= 1.4.1) rack (>= 1.0.0) - rack-protection (1.5.5) + rack-protection (3.0.3) rack rack-test (0.6.3) rack (>= 1.0) @@ -78,22 +80,23 @@ GEM diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.5.0) rspec-support (3.5.0) + ruby2_keywords (0.0.5) ruby_dep (1.5.0) rubyzip (1.3.0) sass (3.4.23) sassc (2.4.0) ffi (~> 1.9) - sinatra (1.4.8) - rack (~> 1.5) - rack-protection (~> 1.4) - tilt (>= 1.3, < 3) - sinatra-contrib (1.4.7) - backports (>= 2.0) + sinatra (3.0.3) + mustermann (~> 3.0) + rack (~> 2.2, >= 2.2.4) + rack-protection (= 3.0.3) + tilt (~> 2.0) + sinatra-contrib (3.0.3) multi_json - rack-protection - rack-test - sinatra (~> 1.4.0) - tilt (>= 1.3, < 3) + mustermann (~> 3.0) + rack-protection (= 3.0.3) + sinatra (= 3.0.3) + tilt (~> 2.0) sprockets (3.7.2) concurrent-ruby (~> 1.0) rack (> 1, < 3) @@ -102,7 +105,7 @@ GEM eventmachine (~> 1.0, >= 1.0.4) rack (>= 1, < 3) thread_safe (0.3.6) - tilt (2.0.6) + tilt (2.0.11) treetop (1.6.8) polyglot (~> 0.3) trollop (2.1.2) @@ -134,8 +137,8 @@ DEPENDENCIES rspec rubyzip sass - sinatra (~> 1.4.0) - sinatra-contrib (~> 1.4.0) + sinatra (~> 3.0.3) + sinatra-contrib (~> 3.0.3) sprockets thin (= 1.8.1) From 11890bc42dff1a369952393e79b96c9d76b770fe Mon Sep 17 00:00:00 2001 From: Melissa Xie Date: Mon, 21 Nov 2022 19:21:57 -0500 Subject: [PATCH 28/35] Bump rack-codehighlighter to latest Otherwise we'll get an exception about `bytesize` being undefined. --- Gemfile.lock | 6 +++--- app.rb | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index e8c50f7af..c1f840cf4 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -47,15 +47,15 @@ GEM multi_json (1.15.0) mustermann (3.0.0) ruby2_keywords (~> 0.0.1) - nokogiri (1.13.2) + nokogiri (1.13.9) mini_portile2 (~> 2.8.0) racc (~> 1.4) polyglot (0.3.5) racc (1.6.0) rack (2.2.4) - rack-codehighlighter (0.5.1) + rack-codehighlighter (0.6.0) nokogiri (>= 1.4.1) - rack (>= 1.0.0) + rack (>= 2.0.0) rack-protection (3.0.3) rack rack-test (0.6.3) diff --git a/app.rb b/app.rb index fdb12c9dc..6d608967d 100755 --- a/app.rb +++ b/app.rb @@ -148,7 +148,7 @@ def doc_path end def back_path - path_parts = cookies[:docs_back_path].try(:split, '/') + path_parts = cookies[:docs_back_path]&.split('/') return unless path_parts && path_parts.length > 2 current_path_parts = request.fullpath.split('/') From e6bd34354f14f00e484c6a828c2ad428ad8cbc26 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 22 Nov 2022 00:24:57 +0000 Subject: [PATCH 29/35] Bump tzinfo from 1.2.9 to 1.2.10 Bumps [tzinfo](https://github.com/tzinfo/tzinfo) from 1.2.9 to 1.2.10. - [Release notes](https://github.com/tzinfo/tzinfo/releases) - [Changelog](https://github.com/tzinfo/tzinfo/blob/master/CHANGES.md) - [Commits](https://github.com/tzinfo/tzinfo/compare/v1.2.9...v1.2.10) --- updated-dependencies: - dependency-name: tzinfo dependency-type: indirect ... Signed-off-by: dependabot[bot] --- Gemfile.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile.lock b/Gemfile.lock index c1f840cf4..ae4b1e12e 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -109,7 +109,7 @@ GEM treetop (1.6.8) polyglot (~> 0.3) trollop (2.1.2) - tzinfo (1.2.9) + tzinfo (1.2.10) thread_safe (~> 0.1) PLATFORMS From 0a58aa4d8b7a3f1092a51ad13d45a8d17817401a Mon Sep 17 00:00:00 2001 From: Peter Cai <222655+pcai@users.noreply.github.com> Date: Wed, 23 Aug 2023 17:42:29 +0000 Subject: [PATCH 30/35] bugfix spanish locale overwriting english --- locales/es/header_sections.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/locales/es/header_sections.yml b/locales/es/header_sections.yml index 21e082978..79751c5ab 100644 --- a/locales/es/header_sections.yml +++ b/locales/es/header_sections.yml @@ -1,4 +1,4 @@ -en: +es: header_section: steps: "Pasos" explanation: "Explicación" From f5d9cdcdeedc2dbd61caea3932d5c9f492cceb2d Mon Sep 17 00:00:00 2001 From: Melissa Xie Date: Fri, 20 Oct 2023 21:28:51 -0400 Subject: [PATCH 31/35] Fix capitalization of GitHub across the board --- sites/installfest/_general-glossary.md | 2 +- sites/installfest/create_a_heroku_account.step | 2 +- sites/installfest/create_an_ssh_key.step | 4 ++-- sites/javascript-to-do-list/_deploying_your_site.md | 8 ++++---- sites/javascript-to-do-list/playing_with_jquery.step | 2 +- .../add_other_features_of_your_choosing.step | 2 +- 6 files changed, 10 insertions(+), 10 deletions(-) diff --git a/sites/installfest/_general-glossary.md b/sites/installfest/_general-glossary.md index 500253e8d..e96914968 100644 --- a/sites/installfest/_general-glossary.md +++ b/sites/installfest/_general-glossary.md @@ -6,7 +6,7 @@ **Git:** A type of **Version Control Software (VCS)**. -**Github:** A site that hosts git repositories. Github also adds a number of tools that aid interaction between developers collaborating on software. +**GitHub:** A site that hosts git repositories. GitHub also adds a number of tools that aid interaction between developers collaborating on software. **Grouping:** Indents and whitespaces are used for grouping code together and simplify readability. Ruby also uses do … end to group. diff --git a/sites/installfest/create_a_heroku_account.step b/sites/installfest/create_a_heroku_account.step index 8b364187d..1f4d06294 100644 --- a/sites/installfest/create_a_heroku_account.step +++ b/sites/installfest/create_a_heroku_account.step @@ -39,7 +39,7 @@ step "Add your SSH key to your Heroku account" do end section 'Optional Step: Create a GitHub account' do - message "Since by now you should have both Git and an SSH key, you can optionally [Create a Github account](create_a_github_account) to share code with your friends." + message "Since by now you should have both Git and an SSH key, you can optionally [Create a GitHub account](create_a_github_account) to share code with your friends." message "You don't need a GitHub account to complete the InstallFest, or the Intro To Rails, Job Board, or Message Board courses." end diff --git a/sites/installfest/create_an_ssh_key.step b/sites/installfest/create_an_ssh_key.step index f7c68254e..431cb02d3 100644 --- a/sites/installfest/create_an_ssh_key.step +++ b/sites/installfest/create_an_ssh_key.step @@ -1,6 +1,6 @@ message "An SSH key uniquely identifies you (and your computer) when your computer is communicating with other computers. Think of an SSH key as a fancy password." -message "You'll need one of these to create your Heroku and Github accounts." +message "You'll need one of these to create your Heroku and GitHub accounts." option "Did you use RailsInstaller on Windows?" do message "Congratulations, you already have an ssh key!" @@ -61,7 +61,7 @@ The key fingerprint is: message "If you look inside `~/.ssh/`, you will notice two files with the same name: `id_rsa` and `id_rsa.pub`." message "`id_rsa.pub` is your **public key** and can be shared freely." message "`id_rsa` is your **private key** and must be kept secret." - message "If someone else gets your private key and your passphrase, then they can pretend to be you and log on to your Heroku or Github accounts and cause mischief!" + message "If someone else gets your private key and your passphrase, then they can pretend to be you and log on to your Heroku or GitHub accounts and cause mischief!" end end diff --git a/sites/javascript-to-do-list/_deploying_your_site.md b/sites/javascript-to-do-list/_deploying_your_site.md index 2277556a1..608d627ed 100644 --- a/sites/javascript-to-do-list/_deploying_your_site.md +++ b/sites/javascript-to-do-list/_deploying_your_site.md @@ -7,7 +7,7 @@ There are three hosting options, depending on how much of a challenge you are lo for: * Use a static site hosting service -* Use git and Github Pages +* Use git and GitHub Pages * Roll your own with a hosting provider ### Using a Static Site Hosting Service @@ -24,10 +24,10 @@ javascript and have a working website. An easy one is Now you have a fully functioning site hosted online! Share the link with your friends and family and wow them with your skills! -### Using Git and Github Pages +### Using Git and GitHub Pages If you like with git and github, take a stab at setting up your site -with [Github Pages](http://pages.github.com/). The easiest thing to do is: +with [GitHub Pages](http://pages.github.com/). The easiest thing to do is: cd . 1. From the terminal, `cd` into your project directory @@ -36,7 +36,7 @@ cd . 1. Commit all the files 1. Create a remote repository on github for the project. 1. Follow their instructions for adding the github remote to your existing repo -1. Follow the instructions on [Github Pages](http://pages.github.com) for +1. Follow the instructions on [GitHub Pages](http://pages.github.com) for setting up a project site from scratch. 1. Make the `gh-pages` the default branch 1. Push it on up! diff --git a/sites/javascript-to-do-list/playing_with_jquery.step b/sites/javascript-to-do-list/playing_with_jquery.step index 4774d0cdc..45159ca1e 100644 --- a/sites/javascript-to-do-list/playing_with_jquery.step +++ b/sites/javascript-to-do-list/playing_with_jquery.step @@ -7,7 +7,7 @@ overview do message <<-MARKDOWN In addition to being a powerful programming language, Javascript allows you to make your web site interactive. You can use it to build anything from a simple animation to a giant web application like Twitter -or Github. It gives you total control to add, remove, or modify content you've made with HTML. +or GitHub. It gives you total control to add, remove, or modify content you've made with HTML. You can also use it to change styles and add or remove classes. In this lesson, we'll also be using jQuery to make interacting with the page easier. diff --git a/sites/message-board/add_other_features_of_your_choosing.step b/sites/message-board/add_other_features_of_your_choosing.step index af68759ee..836d3d56b 100644 --- a/sites/message-board/add_other_features_of_your_choosing.step +++ b/sites/message-board/add_other_features_of_your_choosing.step @@ -6,7 +6,7 @@ Suggestions: * Profile pages for users (enter user’s name or details, have it display alongside posts). * Post/Comment history for individual users (on their profile page?). * Easy user profile pictures with [Gravatar](https://gravatar.com/). -* Add login options with [Omniauth](https://github.com/intridea/omniauth), including Twitter, Facebook, Github, Google, and more. +* Add login options with [Omniauth](https://github.com/intridea/omniauth), including Twitter, Facebook, GitHub, Google, and more. * Check out the Devise [documentation for integrating with Omniauth](https://github.com/plataformatec/devise/wiki/OmniAuth:-Overview). * Fiddle with the layout of the show page so it doesn't look bad. If it looks bad. It probably looks great. * Perhaps fancier post markup with Markdown or something similar. From da930f3b6fa61dacf936ba60d4cc5dec2bd20664 Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Fri, 27 Oct 2023 09:41:31 -0600 Subject: [PATCH 32/35] Fix GitHub link --- lib/doc_page.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/doc_page.rb b/lib/doc_page.rb index 0848933b1..9f4d9e813 100644 --- a/lib/doc_page.rb +++ b/lib/doc_page.rb @@ -41,7 +41,7 @@ def file_name end def git_url - "https://github.com/railsbridge/docs/blob/master/sites/#{@locale}/#{site.name}/#{file_name}" + "https://github.com/railsbridge/docs/blob/master/sites/#{site.name}/#{file_name}" end def src_url From cd6ab141e9d3905f7f457776d6fda41ed119b8ae Mon Sep 17 00:00:00 2001 From: Fer Perales Date: Fri, 27 Oct 2023 10:21:49 -0600 Subject: [PATCH 33/35] Replace TravisCI with GitHub Actions --- .github/workflows/rspec.yml | 28 ++++++++++++++++++++++++++++ .travis.yml | 5 ----- 2 files changed, 28 insertions(+), 5 deletions(-) create mode 100644 .github/workflows/rspec.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/rspec.yml b/.github/workflows/rspec.yml new file mode 100644 index 000000000..82cc27550 --- /dev/null +++ b/.github/workflows/rspec.yml @@ -0,0 +1,28 @@ +name: RSpec + +on: + push: + branches: + - "main" + pull_request: + branches: + - main + +jobs: + rspec: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - name: Set up Ruby + uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + + - name: Install dependencies + run: bundle install + + - name: Run test and linter + run: | + bundle exec rake diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index da2b835e5..000000000 --- a/.travis.yml +++ /dev/null @@ -1,5 +0,0 @@ -language: ruby -rvm: - - 2.3.3 -cache: bundler -sudo: false From a0ccc30bd79d6604d6f4be374b24b0f2cf51268d Mon Sep 17 00:00:00 2001 From: Fernando Perales Date: Fri, 27 Oct 2023 11:28:31 -0600 Subject: [PATCH 34/35] Fix style issues --- .github/workflows/rspec.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/rspec.yml b/.github/workflows/rspec.yml index 82cc27550..e62589a47 100644 --- a/.github/workflows/rspec.yml +++ b/.github/workflows/rspec.yml @@ -3,7 +3,7 @@ name: RSpec on: push: branches: - - "main" + - main pull_request: branches: - main @@ -24,5 +24,5 @@ jobs: run: bundle install - name: Run test and linter - run: | + run: bundle exec rake From 3ce743f11372847e3fe333953990ecb37360fe8d Mon Sep 17 00:00:00 2001 From: Fernando Perales Date: Fri, 3 Nov 2023 11:13:26 -0600 Subject: [PATCH 35/35] Upgrade Ruby to 3.2.2 --- .ruby-version | 2 +- .tool-versions | 1 + Gemfile | 20 ++-- Gemfile.lock | 144 ++++++++++++++++++++------- app.rb | 2 +- assets/stylesheets/font_awesome.scss | 2 - lib/step.rb | 14 +-- spec/app_deck_spec.rb | 2 +- spec/site_syntax_spec.rb | 3 +- 9 files changed, 130 insertions(+), 60 deletions(-) create mode 100644 .tool-versions diff --git a/.ruby-version b/.ruby-version index 49cdd668e..be94e6f53 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.7.6 +3.2.2 diff --git a/.tool-versions b/.tool-versions new file mode 100644 index 000000000..f2a971aa7 --- /dev/null +++ b/.tool-versions @@ -0,0 +1 @@ +ruby 3.2.2 diff --git a/Gemfile b/Gemfile index 5c9605ec8..32eb465d5 100644 --- a/Gemfile +++ b/Gemfile @@ -1,32 +1,32 @@ source "https://rubygems.org/" -ruby '2.7.6' +ruby '3.2.2' gem 'activesupport' -gem "erector", "~> 0.10.0" -gem "sinatra", "~> 3.0.3" -gem "sinatra-contrib", "~> 3.0.3" +gem "erector", github: "erector/erector" +gem "sinatra" +gem "sinatra-contrib" gem "nokogiri" -gem "thin", "1.8.1" +gem "thin" gem 'rack-codehighlighter' gem 'coderay' -gem "deckrb", "~> 0.5.2" +gem "deckrb" gem "sass" gem "redcarpet" gem "rubyzip" -gem "i18n", "~> 0.7" +gem "i18n" gem 'font-awesome-sass' gem 'bootstrap-sass' gem 'jquery-cdn' gem 'sprockets' -gem 'ffi', "1.15.5" -gem 'backports', "3.23.0" +gem 'ffi' +gem 'backports' group :development do gem "rspec" gem "rerun" gem "rake" gem "rack-test" - gem "files", "~> 0.3.0" + gem 'files', github: "alexch/files" gem 'rb-fsevent', :platform => :ruby end diff --git a/Gemfile.lock b/Gemfile.lock index ae4b1e12e..346a686d9 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,18 +1,38 @@ +GIT + remote: https://github.com/alexch/files.git + revision: 4938dd85ed79f421b808e8798764661a71cab5a4 + specs: + files (0.4.0) + +GIT + remote: https://github.com/erector/erector.git + revision: 32cb38e3381889295183230caf8bf334d2f0e82a + specs: + erector (0.10.0) + haml + jeweler + nokogiri + sass + treetop (>= 1.2.3) + GEM remote: https://rubygems.org/ specs: - activesupport (5.2.4.3) + activesupport (6.0.6.1) concurrent-ruby (~> 1.0, >= 1.0.2) i18n (>= 0.7, < 2) minitest (~> 5.1) tzinfo (~> 1.1) - autoprefixer-rails (10.4.2.0) + zeitwerk (~> 2.2, >= 2.2.2) + addressable (2.4.0) + autoprefixer-rails (10.4.15.0) execjs (~> 2) backports (3.23.0) bootstrap-sass (3.4.1) autoprefixer-rails (>= 5.2.1) sassc (>= 2.0.0) - coderay (1.1.1) + builder (3.2.4) + coderay (1.1.3) concurrent-ruby (1.1.9) daemons (1.2.4) deckrb (0.5.2) @@ -25,47 +45,89 @@ GEM redcarpet (~> 2) thin trollop - diff-lcs (1.3) - erector (0.10.0) - treetop (>= 1.2.3) + descendants_tracker (0.0.4) + thread_safe (~> 0.3, >= 0.3.1) + diff-lcs (1.5.0) eventmachine (1.2.3) execjs (2.8.1) + faraday (0.9.2) + multipart-post (>= 1.2, < 3) ffi (1.15.5) - files (0.3.1) - font-awesome-sass (4.7.0) - sass (>= 3.2) - i18n (0.8.1) + font-awesome-sass (6.4.2) + sassc (~> 2.0) + git (1.11.0) + rchardet (~> 1.8) + github_api (0.16.0) + addressable (~> 2.4.0) + descendants_tracker (~> 0.0.4) + faraday (~> 0.8, < 0.10) + hashie (>= 3.4) + mime-types (>= 1.16, < 3.0) + oauth2 (~> 1.0) + haml (6.2.3) + temple (>= 0.8.2) + thor + tilt + hashie (5.0.0) + highline (2.1.0) + i18n (0.9.5) + concurrent-ruby (~> 1.0) + jeweler (2.3.9) + builder + bundler + git (>= 1.2.5) + github_api (~> 0.16.0) + highline (>= 1.6.15) + nokogiri (>= 1.5.10) + psych + rake + rdoc + semver2 jquery-cdn (2.2.4) sprockets (>= 2) json (2.6.1) - listen (3.1.5) + jwt (2.7.1) + listen (3.0.8) rb-fsevent (~> 0.9, >= 0.9.4) rb-inotify (~> 0.9, >= 0.9.7) - ruby_dep (~> 1.2) + mime-types (2.99.3) mini_portile2 (2.8.0) - minitest (5.15.0) + minitest (5.20.0) multi_json (1.15.0) + multi_xml (0.6.0) + multipart-post (2.3.0) mustermann (3.0.0) ruby2_keywords (~> 0.0.1) - nokogiri (1.13.9) + nokogiri (1.14.5) mini_portile2 (~> 2.8.0) racc (~> 1.4) + oauth2 (1.4.8) + faraday (>= 0.8, < 3.0) + jwt (>= 1.0, < 3.0) + multi_json (~> 1.3) + multi_xml (~> 0.5) + rack (>= 1.2, < 3) polyglot (0.3.5) - racc (1.6.0) + psych (5.1.1.1) + stringio + racc (1.7.2) rack (2.2.4) rack-codehighlighter (0.6.0) nokogiri (>= 1.4.1) rack (>= 2.0.0) - rack-protection (3.0.3) - rack + rack-protection (3.1.0) + rack (~> 2.2, >= 2.2.4) rack-test (0.6.3) rack (>= 1.0) - rake (12.3.3) + rake (13.1.0) rb-fsevent (0.9.8) rb-inotify (0.9.8) ffi (>= 0.5.0) + rchardet (1.8.0) + rdoc (6.5.0) + psych (>= 4.0.0) redcarpet (2.3.0) - rerun (0.11.0) + rerun (0.14.0) listen (~> 3.0) rspec (3.5.0) rspec-core (~> 3.5.0) @@ -81,29 +143,36 @@ GEM rspec-support (~> 3.5.0) rspec-support (3.5.0) ruby2_keywords (0.0.5) - ruby_dep (1.5.0) - rubyzip (1.3.0) - sass (3.4.23) + rubyzip (2.3.2) + sass (3.7.4) + sass-listen (~> 4.0.0) + sass-listen (4.0.0) + rb-fsevent (~> 0.9, >= 0.9.4) + rb-inotify (~> 0.9, >= 0.9.7) sassc (2.4.0) ffi (~> 1.9) - sinatra (3.0.3) + semver2 (3.4.2) + sinatra (3.1.0) mustermann (~> 3.0) rack (~> 2.2, >= 2.2.4) - rack-protection (= 3.0.3) + rack-protection (= 3.1.0) tilt (~> 2.0) - sinatra-contrib (3.0.3) + sinatra-contrib (3.1.0) multi_json mustermann (~> 3.0) - rack-protection (= 3.0.3) - sinatra (= 3.0.3) + rack-protection (= 3.1.0) + sinatra (= 3.1.0) tilt (~> 2.0) sprockets (3.7.2) concurrent-ruby (~> 1.0) rack (> 1, < 3) + stringio (3.0.8) + temple (0.10.3) thin (1.8.1) daemons (~> 1.0, >= 1.0.9) eventmachine (~> 1.0, >= 1.0.4) rack (>= 1, < 3) + thor (1.3.0) thread_safe (0.3.6) tilt (2.0.11) treetop (1.6.8) @@ -111,21 +180,22 @@ GEM trollop (2.1.2) tzinfo (1.2.10) thread_safe (~> 0.1) + zeitwerk (2.6.12) PLATFORMS ruby DEPENDENCIES activesupport - backports (= 3.23.0) + backports bootstrap-sass coderay - deckrb (~> 0.5.2) - erector (~> 0.10.0) - ffi (= 1.15.5) - files (~> 0.3.0) + deckrb + erector! + ffi + files! font-awesome-sass - i18n (~> 0.7) + i18n jquery-cdn nokogiri rack-codehighlighter @@ -137,13 +207,13 @@ DEPENDENCIES rspec rubyzip sass - sinatra (~> 3.0.3) - sinatra-contrib (~> 3.0.3) + sinatra + sinatra-contrib sprockets - thin (= 1.8.1) + thin RUBY VERSION - ruby 2.7.6p219 + ruby 3.2.2p53 BUNDLED WITH 2.3.26 diff --git a/app.rb b/app.rb index 39694901c..9070515e4 100755 --- a/app.rb +++ b/app.rb @@ -250,7 +250,7 @@ def render_deck get "/:site/:name.zip" do manifest_path = "#{site_dir}/#{params[:name]}.zip-manifest" - if File.exists?(manifest_path) + if File.exist?(manifest_path) manifest_files = File.read(manifest_path).split("\n") zip_path = File.join(Dir.tmpdir, "#{params[:name]}.zip") FileUtils.rm_rf(zip_path) diff --git a/assets/stylesheets/font_awesome.scss b/assets/stylesheets/font_awesome.scss index 908bb887a..6fccacddb 100644 --- a/assets/stylesheets/font_awesome.scss +++ b/assets/stylesheets/font_awesome.scss @@ -1,3 +1 @@ $fa-font-path: '/fonts/font-awesome/'; - -@import 'http://github.com/font-awesome'; \ No newline at end of file diff --git a/lib/step.rb b/lib/step.rb index 2bc69f6a5..9c8154b85 100644 --- a/lib/step.rb +++ b/lib/step.rb @@ -74,7 +74,7 @@ def insert file ## steps %w[ - steps explanation overview discussion hints challenge + steps explanation overview discussion hints challenge tools_and_references requirements ].each do |type| define_method type.to_sym do |&block| @@ -87,7 +87,7 @@ def insert file end end - def step name = nil, options = {} + def step name = nil, options = {}, &block num = next_step_number a(name: "step#{current_anchor_num}") a(name: options[:anchor_name]) if options[:anchor_name] @@ -98,7 +98,7 @@ def step name = nil, options = {} (!name.nil? ? I18n.t("general.step_title_suffix") : '') text name end - _render_inner_content &Proc.new if block_given? + _render_inner_content(&block) if block_given? end end @@ -131,19 +131,19 @@ def next_step name end end - def situation name + def situation name, &block h1 name - _render_inner_content &Proc.new if block_given? + _render_inner_content(&block) if block_given? end - def option name + def option name, &block num = next_step_number a(:name => "step#{current_anchor_num}") h1 :class => "option" do span I18n.t("general.option", :num => num) text name end - _render_inner_content &Proc.new if block_given? + _render_inner_content(&block) if block_given? end def option_half title diff --git a/spec/app_deck_spec.rb b/spec/app_deck_spec.rb index 27c30efba..2a375105f 100644 --- a/spec/app_deck_spec.rb +++ b/spec/app_deck_spec.rb @@ -41,4 +41,4 @@ def app expect(last_response.body).to include("/* Code ray css */") end end -end \ No newline at end of file +end diff --git a/spec/site_syntax_spec.rb b/spec/site_syntax_spec.rb index 9153deed7..d82950982 100644 --- a/spec/site_syntax_spec.rb +++ b/spec/site_syntax_spec.rb @@ -1,3 +1,4 @@ +require "cgi" require "spec_helper" require_relative "../app" @@ -29,7 +30,7 @@ def app site.docs.each do |doc| it "renders #{doc.filename}" do - path = URI.escape "/#{site.name}/#{doc.name}" + path = CGI.escape "/#{site.name}/#{doc.name}" get path, locale: locale if (last_response.status != 200) errors = last_response.errors