Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
yasulab committed Sep 15, 2014
1 parent 19282f4 commit dbf829c
Show file tree
Hide file tree
Showing 567 changed files with 151,010 additions and 0 deletions.
1 change: 1 addition & 0 deletions CNAME
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
railsguides.jp
16 changes: 16 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
source 'https://rubygems.org'
ruby '2.1.1'

gem 'bundler'
gem 'jekyll'
#gem 'rack-jekyll'
gem 'rack-jekyll', github: 'adaoraul/rack-jekyll'
#gem 'rack-jekyll', github: 'adaoraul/rack-jekyll', ref: '6a4b832c5b2350c8c1263b534ebf02135deb6363'
gem 'unicorn'

# Gems to generate RailsGuides HTML from MD
gem 'rake'
gem 'activesupport'
gem 'actionpack'
gem 'nokogiri'

1 change: 1 addition & 0 deletions Procfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
web: bundle exec unicorn -p $PORT -c ./unicorn.rb
13 changes: 13 additions & 0 deletions app.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"name": "Ruby on Rails ガイド",
"description": "Railsを学び,使うための公式リファレンスマニュアル",
"keywords": [
"Ruby",
"Rails",
"リファレンス",
"参考書",
"マニュアル"
],
"repository": "https://github.com/yasslab/railsguides.jp",
"success_url": "/"
}
5 changes: 5 additions & 0 deletions config.ru
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#require 'rack/jekyll'
require 'bundler/setup'
Bundler.require(:default)

run Rack::Jekyll.new(:destination => '_site')
Empty file added guides/.document
Empty file.
9 changes: 9 additions & 0 deletions guides/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
* Updates the maintenance policy to match the latest versions of Rails

*Matias Korhonen*

* Switched the order of `Applying a default scope` and `Merging of scopes` subsections so default scopes are introduced first.

*Alex Riabov*

Please check [4-1-stable](https://github.com/rails/rails/blob/4-1-stable/guides/CHANGELOG.md) for previous changes.
77 changes: 77 additions & 0 deletions guides/Rakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
namespace :guides do

desc 'Generate guides (for authors), use ONLY=foo to process just "foo.md"'
task :generate => 'generate:html'

namespace :generate do

desc "Generate HTML guides"
task :html do
ENV["WARN_BROKEN_LINKS"] = "1" # authors can't disable this
ruby "rails_guides.rb"
end

desc "Generate .mobi file. The kindlegen executable must be in your PATH. You can get it for free from http://www.amazon.com/kindlepublishing"
task :kindle do
unless `kindlerb -v 2> /dev/null` =~ /kindlerb 0.1.1/
abort "Please `gem install kindlerb` and make sure you have `kindlegen` in your PATH"
end
unless `convert` =~ /convert/
abort "Please install ImageMagick`"
end
ENV['KINDLE'] = '1'
Rake::Task['guides:generate:html'].invoke
end
end

# Validate guides -------------------------------------------------------------------------
desc 'Validate guides, use ONLY=foo to process just "foo.html"'
task :validate do
ruby "w3c_validator.rb"
end

desc "Show help"
task :help do
puts <<-help
Guides are taken from the source directory, and the resulting HTML goes into the
output directory. Assets are stored under files, and copied to output/files as
part of the generation process.
All this process is handled via rake tasks, here's a full list of them:
#{%x[rake -T]}
Some arguments may be passed via environment variables:
WARNINGS=1
Internal links (anchors) are checked, also detects duplicated IDs.
ALL=1
Force generation of all guides.
ONLY=name
Useful if you want to generate only one or a set of guides.
Generate only association_basics.html:
ONLY=assoc
Separate many using commas:
ONLY=assoc,migrations
GUIDES_LANGUAGE
Use it when you want to generate translated guides in
source/<GUIDES_LANGUAGE> folder (such as source/es)
EDGE=1
Indicate generated guides should be marked as edge.
Examples:
$ rake guides:generate ALL=1
$ rake guides:generate EDGE=1
$ rake guides:generate:kindle EDGE=1
$ rake guides:generate GUIDES_LANGUAGE=es
help
end
end

task :default => 'guides:help'
Binary file added guides/archive.zip
Binary file not shown.
Loading

0 comments on commit dbf829c

Please sign in to comment.