History

Update Redis documentation (up to 3.2.0)

Thibaut Courouble committed 10 years ago

Commit 4586dfa1 parent cc60e8c3 files · +9 −3Browse files

Unified · Split

3 files
  1. assets/stylesheets/pages/_redis.scss +1 −1
  2. lib/docs/filters/redis/clean_html.rb +7 −1
  3. lib/docs/scrapers/redis.rb +1 −1
assets/stylesheets/pages/_redis.scss+1−1
@@ -19,7 +19,7 @@ · 18 unmodified lines
1919
2020 // Others
2121
22− > h1, > h2, > .metadata, > h1 ~ p { margin-left: -1rem; }
22+ > h1, > h2, > .metadata, > h1 ~ p, > h1 + pre { margin-left: -1rem; }
2323 > h2 ~ p { margin-left: 0; }
2424
2525 > h2 { @extend %block-heading; }
lib/docs/filters/redis/clean_html.rb+7−1
@@ -2,7 +2,13 @@ module Docs · 1 unmodified line
22 class Redis
33 class CleanHtmlFilter < Filter
44 def call
5− at_css('ul')['class'] = 'commands' if root_page?
5+ if root_page?
6+ at_css('ul')['class'] = 'commands'
7+ else
8+ title = at_css('h1')
9+ title.after("<pre>#{title.content.strip}</pre>")
10+ title.content = title.content.split(' ').first
11+ end
612
713 css('nav', 'aside', 'form', '.anchor-link').remove
814
lib/docs/scrapers/redis.rb+1−1
@@ -1,7 +1,7 @@
11 module Docs
22 class Redis < UrlScraper
33 self.type = 'redis'
4− self.release = 'up to 3.0.7'
4+ self.release = 'up to 3.2.0'
55 self.base_url = 'http://redis.io/commands'
66 self.links = {
77 home: 'http://redis.io/',