moved paginate_path to default config
This commit is contained in:
parent
58d8fef7ec
commit
316cc8559c
|
@ -51,21 +51,22 @@ module Jekyll
|
||||||
# Default options. Overriden by values in _config.yml or command-line opts.
|
# Default options. Overriden by values in _config.yml or command-line opts.
|
||||||
# (Strings rather symbols used for compatability with YAML).
|
# (Strings rather symbols used for compatability with YAML).
|
||||||
DEFAULTS = {
|
DEFAULTS = {
|
||||||
'safe' => false,
|
'safe' => false,
|
||||||
'auto' => false,
|
'auto' => false,
|
||||||
'server' => false,
|
'server' => false,
|
||||||
'server_port' => 4000,
|
'server_port' => 4000,
|
||||||
|
|
||||||
'source' => Dir.pwd,
|
'source' => Dir.pwd,
|
||||||
'destination' => File.join(Dir.pwd, '_site'),
|
'destination' => File.join(Dir.pwd, '_site'),
|
||||||
'plugins' => File.join(Dir.pwd, '_plugins'),
|
'plugins' => File.join(Dir.pwd, '_plugins'),
|
||||||
|
|
||||||
'future' => true,
|
'future' => true,
|
||||||
'lsi' => false,
|
'lsi' => false,
|
||||||
'pygments' => false,
|
'pygments' => false,
|
||||||
'markdown' => 'maruku',
|
'markdown' => 'maruku',
|
||||||
'permalink' => 'date',
|
'permalink' => 'date',
|
||||||
|
'paginate_path' => 'page:num',
|
||||||
|
|
||||||
'markdown_ext' => 'markdown,mkd,mkdn,md',
|
'markdown_ext' => 'markdown,mkd,mkdn,md',
|
||||||
'textile_ext' => 'textile',
|
'textile_ext' => 'textile',
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ module Jekyll
|
||||||
|
|
||||||
private
|
private
|
||||||
def paginate_path(site, num_page)
|
def paginate_path(site, num_page)
|
||||||
format = site.config['paginate_path'] || "page:num"
|
format = site.config['paginate_path']
|
||||||
format.sub(':num', num_page.to_s)
|
format.sub(':num', num_page.to_s)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue