mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
[guides] guides:generate:kindle is the new interface to generate .mobi file instead of using KINDLE=1
This commit is contained in:
parent
1b5e1c1972
commit
15b229e8aa
3 changed files with 3 additions and 18 deletions
|
@ -11,7 +11,7 @@ namespace :guides do
|
|||
ruby "rails_guides.rb"
|
||||
end
|
||||
|
||||
desc "Generate .mobi file"
|
||||
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
|
||||
ENV['KINDLE'] = '1'
|
||||
Rake::Task['guides:generate:html'].invoke
|
||||
|
@ -59,14 +59,10 @@ Some arguments may be passed via environment variables:
|
|||
EDGE=1
|
||||
Indicate generated guides should be marked as edge.
|
||||
|
||||
KINDLE=1
|
||||
Generate .mobi with all the guides.
|
||||
|
||||
Examples:
|
||||
$ rake guides:generate ALL=1
|
||||
$ rake guides:generate KINDLE=1
|
||||
$ rake guides:generate:kindle
|
||||
$ rake guides:generate EDGE=1
|
||||
$ rake guides:generate:kindle EDGE=1
|
||||
$ rake guides:generate GUIDES_LANGUAGE=es
|
||||
help
|
||||
end
|
||||
|
|
|
@ -47,11 +47,6 @@
|
|||
# Set to "1" to indicate generated guides should be marked as edge. This
|
||||
# inserts a badge and changes the preamble of the home page.
|
||||
#
|
||||
# KINDLE
|
||||
# Set to "1" to generate the .mobi with all the guides. The kindlegen
|
||||
# executable must be in your PATH. You can get it for free from
|
||||
# http://www.amazon.com/kindlepublishing
|
||||
#
|
||||
# ---------------------------------------------------------------------------
|
||||
|
||||
require 'set'
|
||||
|
|
|
@ -97,13 +97,7 @@ h3. Kindle Guides
|
|||
|
||||
h4(#generation-kindle). Generation
|
||||
|
||||
To generate guides for the Kindle, you need to provide +KINDLE=1+ as an environment variable:
|
||||
|
||||
<plain>
|
||||
KINDLE=1 bundle exec rake guides:generate
|
||||
</plain>
|
||||
|
||||
or you can use the following task:
|
||||
To generate guides for the Kindle, use the following rake task:
|
||||
|
||||
<plain>
|
||||
bundle exec rake guides:generate:kindle
|
||||
|
|
Loading…
Reference in a new issue