|
|
@ -1,9 +1,11 @@
|
|
|
|
module Docs
|
|
|
|
module Docs
|
|
|
|
class Elixir < UrlScraper
|
|
|
|
class Elixir < UrlScraper
|
|
|
|
|
|
|
|
include MultipleBaseUrls
|
|
|
|
|
|
|
|
|
|
|
|
self.name = 'Elixir'
|
|
|
|
self.name = 'Elixir'
|
|
|
|
self.type = 'elixir'
|
|
|
|
self.type = 'elixir'
|
|
|
|
self.release = '1.3.2'
|
|
|
|
self.release = '1.3.3'
|
|
|
|
self.base_url = 'http://elixir-lang.org/docs/stable/'
|
|
|
|
self.base_urls = ['http://elixir-lang.org/docs/stable/', 'http://elixir-lang.org/getting-started/']
|
|
|
|
self.root_path = 'elixir/api-reference.html'
|
|
|
|
self.root_path = 'elixir/api-reference.html'
|
|
|
|
self.initial_paths = %w(
|
|
|
|
self.initial_paths = %w(
|
|
|
|
eex/EEx.html
|
|
|
|
eex/EEx.html
|
|
|
@ -19,7 +21,9 @@ module Docs
|
|
|
|
|
|
|
|
|
|
|
|
html_filters.push 'elixir/clean_html', 'elixir/entries', 'title'
|
|
|
|
html_filters.push 'elixir/clean_html', 'elixir/entries', 'title'
|
|
|
|
|
|
|
|
|
|
|
|
options[:container] = "#content"
|
|
|
|
options[:container] = ->(filter) {
|
|
|
|
|
|
|
|
filter.current_url.path.start_with?('/getting-started') ? '#main' : '#content'
|
|
|
|
|
|
|
|
}
|
|
|
|
options[:title] = false
|
|
|
|
options[:title] = false
|
|
|
|
options[:root_title] = 'Elixir'
|
|
|
|
options[:root_title] = 'Elixir'
|
|
|
|
|
|
|
|
|
|
|
@ -27,5 +31,9 @@ module Docs
|
|
|
|
© 2012–2016 Plataformatec<br>
|
|
|
|
© 2012–2016 Plataformatec<br>
|
|
|
|
Licensed under the Apache License, Version 2.0.
|
|
|
|
Licensed under the Apache License, Version 2.0.
|
|
|
|
HTML
|
|
|
|
HTML
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def initial_urls
|
|
|
|
|
|
|
|
super.tap { |urls| urls.last << 'introduction.html' }
|
|
|
|
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|