jekyll 2.5.3 → 3.0.0.pre.beta1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of jekyll might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/LICENSE +3 -3
- data/README.markdown +4 -4
- data/bin/jekyll +4 -6
- data/lib/jekyll.rb +8 -1
- data/lib/jekyll/cleaner.rb +8 -0
- data/lib/jekyll/collection.rb +1 -2
- data/lib/jekyll/command.rb +1 -0
- data/lib/jekyll/commands/build.rb +3 -1
- data/lib/jekyll/commands/clean.rb +42 -0
- data/lib/jekyll/configuration.rb +13 -11
- data/lib/jekyll/converters/markdown.rb +3 -6
- data/lib/jekyll/converters/markdown/kramdown_parser.rb +2 -2
- data/lib/jekyll/converters/markdown/rdiscount_parser.rb +1 -1
- data/lib/jekyll/converters/markdown/redcarpet_parser.rb +3 -3
- data/lib/jekyll/convertible.rb +6 -0
- data/lib/jekyll/deprecator.rb +0 -17
- data/lib/jekyll/document.rb +5 -3
- data/lib/jekyll/excerpt.rb +1 -2
- data/lib/jekyll/external.rb +59 -0
- data/lib/jekyll/filters.rb +12 -20
- data/lib/jekyll/frontmatter_defaults.rb +1 -1
- data/lib/jekyll/layout.rb +4 -0
- data/lib/jekyll/log_adapter.rb +5 -2
- data/lib/jekyll/post.rb +15 -6
- data/lib/jekyll/regenerator.rb +141 -0
- data/lib/jekyll/renderer.rb +12 -5
- data/lib/jekyll/site.rb +32 -17
- data/lib/jekyll/static_file.rb +4 -5
- data/lib/jekyll/tags/highlight.rb +1 -1
- data/lib/jekyll/tags/include.rb +10 -1
- data/lib/jekyll/utils.rb +52 -15
- data/lib/jekyll/version.rb +1 -1
- data/lib/site_template/_includes/footer.html +5 -5
- data/lib/site_template/_includes/head.html +1 -1
- data/lib/site_template/_layouts/page.html +4 -4
- data/lib/site_template/_layouts/post.html +6 -6
- data/lib/site_template/_sass/_layout.scss +4 -4
- metadata +11 -248
- data/lib/jekyll/commands/docs.rb +0 -30
- data/lib/jekyll/converters/textile.rb +0 -56
data/lib/jekyll/commands/docs.rb
DELETED
@@ -1,30 +0,0 @@
|
|
1
|
-
module Jekyll
|
2
|
-
module Commands
|
3
|
-
class Docs < Command
|
4
|
-
|
5
|
-
class << self
|
6
|
-
|
7
|
-
def init_with_program(prog)
|
8
|
-
prog.command(:docs) do |c|
|
9
|
-
c.syntax 'docs'
|
10
|
-
c.description "Launch local server with docs for Jekyll v#{Jekyll::VERSION}"
|
11
|
-
|
12
|
-
c.option 'port', '-P', '--port [PORT]', 'Port to listen on'
|
13
|
-
c.option 'host', '-H', '--host [HOST]', 'Host to bind to'
|
14
|
-
|
15
|
-
c.action do |args, options|
|
16
|
-
options.merge!({
|
17
|
-
'source' => File.expand_path("../../../site", File.dirname(__FILE__)),
|
18
|
-
'destination' => File.expand_path("../../../site/_site", File.dirname(__FILE__))
|
19
|
-
})
|
20
|
-
Jekyll::Commands::Build.process(options)
|
21
|
-
Jekyll::Commands::Serve.process(options)
|
22
|
-
end
|
23
|
-
end
|
24
|
-
end
|
25
|
-
|
26
|
-
end
|
27
|
-
|
28
|
-
end
|
29
|
-
end
|
30
|
-
end
|
@@ -1,56 +0,0 @@
|
|
1
|
-
module Jekyll
|
2
|
-
module Converters
|
3
|
-
class Textile < Converter
|
4
|
-
safe true
|
5
|
-
|
6
|
-
highlighter_prefix '<notextile>'
|
7
|
-
highlighter_suffix '</notextile>'
|
8
|
-
|
9
|
-
def setup
|
10
|
-
return if @setup
|
11
|
-
require 'redcloth'
|
12
|
-
@setup = true
|
13
|
-
rescue LoadError
|
14
|
-
STDERR.puts 'You are missing a library required for Textile. Please run:'
|
15
|
-
STDERR.puts ' $ [sudo] gem install RedCloth'
|
16
|
-
raise Errors::FatalException.new("Missing dependency: RedCloth")
|
17
|
-
end
|
18
|
-
|
19
|
-
def extname_matches_regexp
|
20
|
-
@extname_matches_regexp ||= Regexp.new(
|
21
|
-
'(' + @config['textile_ext'].gsub(',','|') +')$',
|
22
|
-
Regexp::IGNORECASE
|
23
|
-
)
|
24
|
-
end
|
25
|
-
|
26
|
-
def matches(ext)
|
27
|
-
ext =~ extname_matches_regexp
|
28
|
-
end
|
29
|
-
|
30
|
-
def output_ext(ext)
|
31
|
-
".html"
|
32
|
-
end
|
33
|
-
|
34
|
-
def convert(content)
|
35
|
-
setup
|
36
|
-
|
37
|
-
# Shortcut if config doesn't contain RedCloth section
|
38
|
-
return RedCloth.new(content).to_html if @config['redcloth'].nil?
|
39
|
-
|
40
|
-
# List of attributes defined on RedCloth
|
41
|
-
# (from https://github.com/jgarber/redcloth/blob/master/lib/redcloth/textile_doc.rb)
|
42
|
-
attrs = ['filter_classes', 'filter_html', 'filter_ids', 'filter_styles',
|
43
|
-
'hard_breaks', 'lite_mode', 'no_span_caps', 'sanitize_html']
|
44
|
-
|
45
|
-
r = RedCloth.new(content)
|
46
|
-
|
47
|
-
# Set attributes in r if they are NOT nil in the config
|
48
|
-
attrs.each do |attr|
|
49
|
-
r.instance_variable_set("@#{attr}".to_sym, @config['redcloth'][attr]) unless @config['redcloth'][attr].nil?
|
50
|
-
end
|
51
|
-
|
52
|
-
r.to_html
|
53
|
-
end
|
54
|
-
end
|
55
|
-
end
|
56
|
-
end
|