From be54303fa93025342526a522fb7322e19a7642ad Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Mon, 2 Sep 2013 14:00:58 +0200 Subject: [PATCH 001/133] Use File#read instead of #readlines.join construct --- features/step_definitions/jekyll_steps.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/features/step_definitions/jekyll_steps.rb b/features/step_definitions/jekyll_steps.rb index a1a1b797..483e61ec 100644 --- a/features/step_definitions/jekyll_steps.rb +++ b/features/step_definitions/jekyll_steps.rb @@ -142,11 +142,11 @@ Then /^the (.*) directory should exist$/ do |dir| end Then /^I should see "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(text).match(File.open(file).readlines.join) + assert Regexp.new(text).match(File.read(file)) end Then /^I should see exactly "(.*)" in "(.*)"$/ do |text, file| - assert_equal text, File.open(file).readlines.join.strip + assert_equal text, File.read(file).strip end Then /^I should not see "(.*)" in "(.*)"$/ do |text, file| @@ -154,7 +154,7 @@ Then /^I should not see "(.*)" in "(.*)"$/ do |text, file| end Then /^I should see escaped "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(Regexp.escape(text)).match(File.open(file).readlines.join) + assert Regexp.new(Regexp.escape(text)).match(File.read(file)) end Then /^the "(.*)" file should exist$/ do |file| @@ -166,9 +166,9 @@ Then /^the "(.*)" file should not exist$/ do |file| end Then /^I should see today's time in "(.*)"$/ do |file| - assert_match Regexp.new(Regexp.escape(Time.now.to_s)), File.open(file).readlines.join + assert_match Regexp.new(Regexp.escape(Time.now.to_s)), File.read(file) end Then /^I should see today's date in "(.*)"$/ do |file| - assert_match Regexp.new(Date.today.to_s), File.open(file).readlines.join + assert_match Regexp.new(Date.today.to_s), File.read(file) end From 89f0d69b07af8f9e4aac176b5e21b0bf0b939727 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Sat, 7 Sep 2013 18:07:54 +0200 Subject: [PATCH 002/133] Revert to #readlines#join, but enclose it in a function This is necessary to preserve the handling of \r\n and \n line endings. --- features/step_definitions/jekyll_steps.rb | 12 ++++++------ features/support/env.rb | 6 ++++++ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/features/step_definitions/jekyll_steps.rb b/features/step_definitions/jekyll_steps.rb index 483e61ec..cc8353e0 100644 --- a/features/step_definitions/jekyll_steps.rb +++ b/features/step_definitions/jekyll_steps.rb @@ -142,19 +142,19 @@ Then /^the (.*) directory should exist$/ do |dir| end Then /^I should see "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(text).match(File.read(file)) + assert Regexp.new(text).match(read_file(file)) end Then /^I should see exactly "(.*)" in "(.*)"$/ do |text, file| - assert_equal text, File.read(file).strip + assert_equal text, read_file(file).strip end Then /^I should not see "(.*)" in "(.*)"$/ do |text, file| - assert_no_match Regexp.new(text), File.read(file) + assert_no_match Regexp.new(text), read_file(file) end Then /^I should see escaped "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(Regexp.escape(text)).match(File.read(file)) + assert Regexp.new(Regexp.escape(text)).match(read_file(file)) end Then /^the "(.*)" file should exist$/ do |file| @@ -166,9 +166,9 @@ Then /^the "(.*)" file should not exist$/ do |file| end Then /^I should see today's time in "(.*)"$/ do |file| - assert_match Regexp.new(Regexp.escape(Time.now.to_s)), File.read(file) + assert_match Regexp.new(Regexp.escape(Time.now.to_s)), read_file(file) end Then /^I should see today's date in "(.*)"$/ do |file| - assert_match Regexp.new(Date.today.to_s), File.read(file) + assert_match Regexp.new(Date.today.to_s), read_file(file) end diff --git a/features/support/env.rb b/features/support/env.rb index efe6b1b6..dfab55c8 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -35,5 +35,11 @@ def location(folder, direction) [before || '.', after || '.'] end +def read_file(path) + File.open(path) do |file| + file.readlines.join # avoid differences with \n and \r\n line endings + end +end + # work around "invalid option: --format" cucumber bug (see #296) Test::Unit.run = true if RUBY_VERSION < '1.9' From 3a18157d204fcc5b28e496707756e632037aec36 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Tue, 10 Sep 2013 19:09:33 +0200 Subject: [PATCH 003/133] rename the new function --- features/step_definitions/jekyll_steps.rb | 12 ++++++------ features/support/env.rb | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/features/step_definitions/jekyll_steps.rb b/features/step_definitions/jekyll_steps.rb index cc8353e0..66ae8eaf 100644 --- a/features/step_definitions/jekyll_steps.rb +++ b/features/step_definitions/jekyll_steps.rb @@ -142,19 +142,19 @@ Then /^the (.*) directory should exist$/ do |dir| end Then /^I should see "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(text).match(read_file(file)) + assert Regexp.new(text).match(file_contents(file)) end Then /^I should see exactly "(.*)" in "(.*)"$/ do |text, file| - assert_equal text, read_file(file).strip + assert_equal text, file_contents(file).strip end Then /^I should not see "(.*)" in "(.*)"$/ do |text, file| - assert_no_match Regexp.new(text), read_file(file) + assert_no_match Regexp.new(text), file_contents(file) end Then /^I should see escaped "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(Regexp.escape(text)).match(read_file(file)) + assert Regexp.new(Regexp.escape(text)).match(file_contents(file)) end Then /^the "(.*)" file should exist$/ do |file| @@ -166,9 +166,9 @@ Then /^the "(.*)" file should not exist$/ do |file| end Then /^I should see today's time in "(.*)"$/ do |file| - assert_match Regexp.new(Regexp.escape(Time.now.to_s)), read_file(file) + assert_match Regexp.new(Regexp.escape(Time.now.to_s)), file_contents(file) end Then /^I should see today's date in "(.*)"$/ do |file| - assert_match Regexp.new(Date.today.to_s), read_file(file) + assert_match Regexp.new(Date.today.to_s), file_contents(file) end diff --git a/features/support/env.rb b/features/support/env.rb index dfab55c8..e426a4ab 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -35,7 +35,7 @@ def location(folder, direction) [before || '.', after || '.'] end -def read_file(path) +def file_contents(path) File.open(path) do |file| file.readlines.join # avoid differences with \n and \r\n line endings end From f20b7d8bd299756295dc1a7506997f0967b3703d Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Thu, 12 Sep 2013 20:19:56 +0200 Subject: [PATCH 004/133] use assert_match --- features/step_definitions/jekyll_steps.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/features/step_definitions/jekyll_steps.rb b/features/step_definitions/jekyll_steps.rb index 66ae8eaf..21f24062 100644 --- a/features/step_definitions/jekyll_steps.rb +++ b/features/step_definitions/jekyll_steps.rb @@ -142,7 +142,7 @@ Then /^the (.*) directory should exist$/ do |dir| end Then /^I should see "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(text).match(file_contents(file)) + assert_match Regexp.new(text), file_contents(file) end Then /^I should see exactly "(.*)" in "(.*)"$/ do |text, file| @@ -154,7 +154,7 @@ Then /^I should not see "(.*)" in "(.*)"$/ do |text, file| end Then /^I should see escaped "(.*)" in "(.*)"$/ do |text, file| - assert Regexp.new(Regexp.escape(text)).match(file_contents(file)) + assert_match Regexp.new(Regexp.escape(text)), file_contents(file) end Then /^the "(.*)" file should exist$/ do |file| From 29d0841e9798e4ce79f05512d577211cf8a38560 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Thu, 12 Sep 2013 22:36:42 +0200 Subject: [PATCH 005/133] #to_sym is called by #symbolize_keys --- lib/jekyll/converters/markdown/kramdown_parser.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/converters/markdown/kramdown_parser.rb b/lib/jekyll/converters/markdown/kramdown_parser.rb index be9e80b4..caeb5b65 100644 --- a/lib/jekyll/converters/markdown/kramdown_parser.rb +++ b/lib/jekyll/converters/markdown/kramdown_parser.rb @@ -16,7 +16,7 @@ module Jekyll if @config['kramdown']['use_coderay'] %w[wrap line_numbers line_numbers_start tab_width bold_every css default_lang].each do |opt| key = "coderay_#{opt}" - @config['kramdown'][key.to_sym] = @config['kramdown']['coderay'][key] unless @config['kramdown'].has_key?(key) + @config['kramdown'][key] = @config['kramdown']['coderay'][key] unless @config['kramdown'].has_key?(key) end end From 76d56c2352d4923094f7c7c55f7229608214a9b4 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Thu, 12 Sep 2013 22:23:58 +0200 Subject: [PATCH 006/133] shorten test code by moving converter instantiation to #setup --- test/test_kramdown.rb | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/test/test_kramdown.rb b/test/test_kramdown.rb index eed8b97f..a442573d 100644 --- a/test/test_kramdown.rb +++ b/test/test_kramdown.rb @@ -15,17 +15,16 @@ class TestKramdown < Test::Unit::TestCase 'smart_quotes' => 'lsquo,rsquo,ldquo,rdquo' } } + @markdown = Converters::Markdown.new(@config) end # http://kramdown.rubyforge.org/converter/html.html#options should "pass kramdown options" do - markdown = Converters::Markdown.new(@config) - assert_equal "

Some Header

", markdown.convert('# Some Header #').strip + assert_equal "

Some Header

", @markdown.convert('# Some Header #').strip end should "convert quotes to smart quotes" do - markdown = Converters::Markdown.new(@config) - assert_match /

(“|“)Pit(’|’)hy(”|”)<\/p>/, markdown.convert(%{"Pit'hy"}).strip + assert_match /

(“|“)Pit(’|’)hy(”|”)<\/p>/, @markdown.convert(%{"Pit'hy"}).strip override = { 'kramdown' => { 'smart_quotes' => 'lsaquo,rsaquo,laquo,raquo' } } markdown = Converters::Markdown.new(@config.deep_merge(override)) From ed58ba15082333fe9f0f287288ce33a62202232e Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Thu, 12 Sep 2013 22:34:05 +0200 Subject: [PATCH 007/133] add tests for moving of coderay settings for kramdown --- test/test_kramdown.rb | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/test/test_kramdown.rb b/test/test_kramdown.rb index a442573d..1d4c09ff 100644 --- a/test/test_kramdown.rb +++ b/test/test_kramdown.rb @@ -12,9 +12,17 @@ class TestKramdown < Test::Unit::TestCase 'footnote_nr' => 1, 'entity_output' => 'as_char', 'toc_levels' => '1..6', - 'smart_quotes' => 'lsquo,rsquo,ldquo,rdquo' + 'smart_quotes' => 'lsquo,rsquo,ldquo,rdquo', + + 'use_coderay' => true, + 'coderay_bold_every'=> 12, + 'coderay' => { + 'coderay_css' => :style, + 'coderay_bold_every' => 8 + } } } + @config = Jekyll.configuration(@config) @markdown = Converters::Markdown.new(@config) end @@ -30,5 +38,25 @@ class TestKramdown < Test::Unit::TestCase markdown = Converters::Markdown.new(@config.deep_merge(override)) assert_match /

(«|«)Pit(›|›)hy(»|»)<\/p>/, markdown.convert(%{"Pit'hy"}).strip end + + context "moving up nested coderay options" do + setup do + @markdown.convert('some markup') + @converter_config = @markdown.instance_variable_get(:@config)['kramdown'] + end + + should "work correctly" do + assert_equal :style, @converter_config['coderay_css'] + end + + should "also work for defaults" do + default = Jekyll::Configuration::DEFAULTS['kramdown']['coderay']['coderay_tab_width'] + assert_equal default, @converter_config['coderay_tab_width'] + end + + should "not overwrite" do + assert_equal 12, @converter_config['coderay_bold_every'] + end + end end end From aa6ee14fb7b6fa808c29898640a21c67f99b9c51 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 27 Sep 2013 15:38:38 -0400 Subject: [PATCH 008/133] Get some nice Regexp which is agnostic about the seconds. --- features/step_definitions/jekyll_steps.rb | 2 +- features/support/env.rb | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/features/step_definitions/jekyll_steps.rb b/features/step_definitions/jekyll_steps.rb index 56da1d11..81d68da9 100644 --- a/features/step_definitions/jekyll_steps.rb +++ b/features/step_definitions/jekyll_steps.rb @@ -170,7 +170,7 @@ Then /^the "(.*)" file should not exist$/ do |file| end Then /^I should see today's time in "(.*)"$/ do |file| - assert_match Regexp.new(Regexp.escape(Time.now.to_s)), File.open(file).readlines.join + assert_match Regexp.new(seconds_agnostic_time(Time.now)), File.open(file).readlines.join end Then /^I should see today's date in "(.*)"$/ do |file| diff --git a/features/support/env.rb b/features/support/env.rb index 5c7db508..5c550fe4 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -40,5 +40,15 @@ def location(folder, direction) [before || '.', after || '.'] end +def seconds_agnostic_time(datetime = Time.now) + pieces = datetime.to_s.split(" ") + time = "#{pieces[1].split(':').first}:#{pieces[1].split(':')[1]}:\\d{2}" + [ + Regexp.escape(pieces[0]), + time, + Regexp.escape(pieces.last) + ].join("\\ ") +end + # work around "invalid option: --format" cucumber bug (see #296) Test::Unit.run = true if RUBY_VERSION < '1.9' From 2dd7964926306c1850906d92e079802fa5c73123 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 27 Sep 2013 21:56:24 -0400 Subject: [PATCH 009/133] C'mon, you're a Ruby developer. What are you doing. --- features/support/env.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/features/support/env.rb b/features/support/env.rb index 5c550fe4..0d296d76 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -41,12 +41,12 @@ def location(folder, direction) end def seconds_agnostic_time(datetime = Time.now) - pieces = datetime.to_s.split(" ") - time = "#{pieces[1].split(':').first}:#{pieces[1].split(':')[1]}:\\d{2}" + date, time, zone = datetime.strftime("%Y-%m-%d %H:%M:%S %z").split(" ") + hours, minutes, _ = time.split(":") [ - Regexp.escape(pieces[0]), - time, - Regexp.escape(pieces.last) + Regexp.escape(date), + "#{hour}:#{minutes}:\\d{2}", + Regexp.escape(zone) ].join("\\ ") end From d958fd5679837b8362984474b8f52901ecca0c3c Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Sat, 28 Sep 2013 13:26:55 -0400 Subject: [PATCH 010/133] Clean it up, clean it up. --- features/support/env.rb | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/features/support/env.rb b/features/support/env.rb index 0d296d76..70437a79 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -41,11 +41,10 @@ def location(folder, direction) end def seconds_agnostic_time(datetime = Time.now) - date, time, zone = datetime.strftime("%Y-%m-%d %H:%M:%S %z").split(" ") - hours, minutes, _ = time.split(":") + date, time, zone = datetime.strftime("%Y-%m-%d %H:%M %z").split(" ") [ Regexp.escape(date), - "#{hour}:#{minutes}:\\d{2}", + "#{time}:\\d{2}", Regexp.escape(zone) ].join("\\ ") end From 425885460fb62c3587d0ce7e3ad3fc17d66d0849 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Sat, 28 Sep 2013 14:16:57 -0400 Subject: [PATCH 011/133] DARN YOU RUBY 1.8.7 AND YOUR DIFFERENT TIME.TO_S METHOD --- features/support/env.rb | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/features/support/env.rb b/features/support/env.rb index 70437a79..7760bc3f 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -40,8 +40,16 @@ def location(folder, direction) [before || '.', after || '.'] end -def seconds_agnostic_time(datetime = Time.now) - date, time, zone = datetime.strftime("%Y-%m-%d %H:%M %z").split(" ") +def seconds_agnostic_datetime(datetime = Time.now) + pieces = datetime.to_s.split(" ") + if pieces.size == 6 # Ruby 1.8.7 + date = pieces[0..2].join(" ") + time = seconds_agnostic_time(pieces[3]) + zone = pieces[4..5].join(" ") + else # Ruby 1.9.1 or greater + date, time, zone = pieces + time = seconds_agnostic_time(time) + end [ Regexp.escape(date), "#{time}:\\d{2}", @@ -49,5 +57,13 @@ def seconds_agnostic_time(datetime = Time.now) ].join("\\ ") end +def seconds_agnostic_time(time) + if time.is_a? Time + time = time.strftime("%H:%M:%S") + end + hour, minutes, _ = time.split(":") + "#{hour}:#{minutes}" +end + # work around "invalid option: --format" cucumber bug (see #296) Test::Unit.run = true if RUBY_VERSION < '1.9' From 8fe25a695897a04e11356494437f50b67f0c643e Mon Sep 17 00:00:00 2001 From: Dmitry Chestnykh Date: Mon, 30 Sep 2013 03:10:57 +0200 Subject: [PATCH 012/133] Replace directory_watcher with listen. Directory_watcher consumed ~25% CPU on big Jekyll projects (depending on the number of watched files), since it polled for changes every second. Listen is easier on CPU, as it uses directory change notifications provided by OS (currently OS X and Linux), falling back to polling when they are not available. --- jekyll.gemspec | 2 +- lib/jekyll/commands/build.rb | 17 ++++++++--------- 2 files changed, 9 insertions(+), 10 deletions(-) diff --git a/jekyll.gemspec b/jekyll.gemspec index f726d4d1..f9b46f73 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -25,7 +25,7 @@ Gem::Specification.new do |s| s.add_runtime_dependency('liquid', "~> 2.5.2") s.add_runtime_dependency('classifier', "~> 1.3") - s.add_runtime_dependency('directory_watcher', "~> 1.4.1") + s.add_runtime_dependency('listen', "~> 1.3.1") s.add_runtime_dependency('maruku', "~> 0.5") s.add_runtime_dependency('pygments.rb', "~> 0.5.0") s.add_runtime_dependency('commander', "~> 4.1.3") diff --git a/lib/jekyll/commands/build.rb b/lib/jekyll/commands/build.rb index fe49b54b..901806c7 100644 --- a/lib/jekyll/commands/build.rb +++ b/lib/jekyll/commands/build.rb @@ -31,25 +31,24 @@ module Jekyll # # Returns nothing. def self.watch(site, options) - require 'directory_watcher' + require 'listen' + require 'pathname' source = options['source'] - destination = options['destination'] + destination = Pathname.new(options['destination']) + .relative_path_from(Pathname.new(source)) + .to_path Jekyll.logger.info "Auto-regeneration:", "enabled" - dw = DirectoryWatcher.new(source, :glob => self.globs(source, destination), :pre_load => true) - dw.interval = 1 - - dw.add_observer do |*args| + Listen.to(source, :ignore => %r{#{Regexp.escape(destination)}}) do |modified, added, removed| t = Time.now.strftime("%Y-%m-%d %H:%M:%S") - print Jekyll.logger.formatted_topic("Regenerating:") + "#{args.size} files at #{t} " + n = modified.length + added.length + removed.length + print Jekyll.logger.formatted_topic("Regenerating:") + "#{n} files at #{t} " self.process_site(site) puts "...done." end - dw.start - unless options['serving'] trap("INT") do puts " Halting auto-regeneration." From dfaf1f45cc5c587a210ccb5c8ecc701fca3aa236 Mon Sep 17 00:00:00 2001 From: Dmitry Chestnykh Date: Mon, 30 Sep 2013 05:11:15 +0200 Subject: [PATCH 013/133] Remove require 'pathname': already included. --- lib/jekyll/commands/build.rb | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/jekyll/commands/build.rb b/lib/jekyll/commands/build.rb index 901806c7..79ab11bb 100644 --- a/lib/jekyll/commands/build.rb +++ b/lib/jekyll/commands/build.rb @@ -32,7 +32,6 @@ module Jekyll # Returns nothing. def self.watch(site, options) require 'listen' - require 'pathname' source = options['source'] destination = Pathname.new(options['destination']) From 58cab6b0505504dc567f9385ad1d451219bcf08d Mon Sep 17 00:00:00 2001 From: Dmitry Chestnykh Date: Mon, 30 Sep 2013 05:55:38 +0200 Subject: [PATCH 014/133] Handle destinations outside of source. --- lib/jekyll/commands/build.rb | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/lib/jekyll/commands/build.rb b/lib/jekyll/commands/build.rb index 79ab11bb..dd5fc967 100644 --- a/lib/jekyll/commands/build.rb +++ b/lib/jekyll/commands/build.rb @@ -34,13 +34,20 @@ module Jekyll require 'listen' source = options['source'] - destination = Pathname.new(options['destination']) - .relative_path_from(Pathname.new(source)) - .to_path + destination = options['destination'] + + begin + ignored = Regexp.new(Regexp.escape(Pathname.new(destination) + .relative_path_from(Pathname.new(source)) + .to_path)) + rescue ArgumentError + # Destination is outside the source, no need to ignore it. + ignored = nil + end Jekyll.logger.info "Auto-regeneration:", "enabled" - Listen.to(source, :ignore => %r{#{Regexp.escape(destination)}}) do |modified, added, removed| + Listen.to(source, :ignore => ignored) do |modified, added, removed| t = Time.now.strftime("%Y-%m-%d %H:%M:%S") n = modified.length + added.length + removed.length print Jekyll.logger.formatted_topic("Regenerating:") + "#{n} files at #{t} " From bf1d9a79c4ee7c408127ca0e46a8b7d2340238fa Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 4 Oct 2013 14:27:58 -0400 Subject: [PATCH 015/133] Add support for gem-based plugins. --- lib/jekyll/configuration.rb | 1 + lib/jekyll/site.rb | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lib/jekyll/configuration.rb b/lib/jekyll/configuration.rb index de903a96..5e923c27 100644 --- a/lib/jekyll/configuration.rb +++ b/lib/jekyll/configuration.rb @@ -12,6 +12,7 @@ module Jekyll 'layouts' => '_layouts', 'data_source' => '_data', 'keep_files' => ['.git','.svn'], + 'gems' => [], 'timezone' => nil, # use the local timezone diff --git a/lib/jekyll/site.rb b/lib/jekyll/site.rb index 5cad11c8..3303f536 100644 --- a/lib/jekyll/site.rb +++ b/lib/jekyll/site.rb @@ -3,7 +3,7 @@ module Jekyll attr_accessor :config, :layouts, :posts, :pages, :static_files, :categories, :exclude, :include, :source, :dest, :lsi, :pygments, :permalink_style, :tags, :time, :future, :safe, :plugins, :limit_posts, - :show_drafts, :keep_files, :baseurl, :data, :file_read_opts + :show_drafts, :keep_files, :baseurl, :data, :file_read_opts, :gems attr_accessor :converters, :generators @@ -13,7 +13,7 @@ module Jekyll def initialize(config) self.config = config.clone - %w[safe lsi pygments baseurl exclude include future show_drafts limit_posts keep_files].each do |opt| + %w[safe lsi pygments baseurl exclude include future show_drafts limit_posts keep_files gems].each do |opt| self.send("#{opt}=", config[opt]) end @@ -77,6 +77,9 @@ module Jekyll require f end end + self.gems.each do |gem| + require gem + end end self.converters = instantiate_subclasses(Jekyll::Converter) From 310688297b2333cc6e5c9e240712db6e0a1d2ffd Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 4 Oct 2013 14:32:10 -0400 Subject: [PATCH 016/133] I guess we'll wait until v2.0 to switch to absolute permalinks. --- lib/jekyll/configuration.rb | 2 +- lib/jekyll/site.rb | 2 +- site/docs/upgrading.md | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/jekyll/configuration.rb b/lib/jekyll/configuration.rb index 5e923c27..442fa5e6 100644 --- a/lib/jekyll/configuration.rb +++ b/lib/jekyll/configuration.rb @@ -27,7 +27,7 @@ module Jekyll 'pygments' => true, 'relative_permalinks' => true, # backwards-compatibility with < 1.0 - # will be set to false once 1.1 hits + # will be set to false once 2.0 hits 'markdown' => 'maruku', 'permalink' => 'date', diff --git a/lib/jekyll/site.rb b/lib/jekyll/site.rb index 3303f536..3b9699d2 100644 --- a/lib/jekyll/site.rb +++ b/lib/jekyll/site.rb @@ -394,7 +394,7 @@ module Jekyll def relative_permalinks_deprecation_method if config['relative_permalinks'] && !@deprecated_relative_permalinks $stderr.puts # Places newline after "Generating..." - Jekyll.logger.warn "Deprecation:", "Starting in 1.1, permalinks for pages" + + Jekyll.logger.warn "Deprecation:", "Starting in 2.0, permalinks for pages" + " in subfolders must be relative to the" + " site source directory, not the parent" + " directory. Check http://jekyllrb.com/docs/upgrading/"+ diff --git a/site/docs/upgrading.md b/site/docs/upgrading.md index c15218fb..3cf5a1ef 100644 --- a/site/docs/upgrading.md +++ b/site/docs/upgrading.md @@ -42,7 +42,7 @@ rebuild each time a file changes, just add the `--watch` flag at the end. ### Absolute Permalinks In Jekyll v1.0, we introduced absolute permalinks for pages in subdirectories. -Until v1.1, it is **opt-in**. Starting with v1.1, however, absolute permalinks +Until v2.0, it is **opt-in**. Starting with v2.0, however, absolute permalinks will become **opt-out**, meaning Jekyll will default to using absolute permalinks instead of relative permalinks. @@ -50,9 +50,9 @@ instead of relative permalinks. * To continue using relative permalinks, set `relative_permalinks: true` in your configuration file.

diff --git a/test/test_filters.rb b/test/test_filters.rb index 6af0d705..28e9612d 100644 --- a/test/test_filters.rb +++ b/test/test_filters.rb @@ -98,5 +98,16 @@ class TestFilters < Test::Unit::TestCase should "escape space as %20" do assert_equal "my%20things", @filter.uri_escape("my things") end + + context "jsonify filter" do + should "convert hash to json" do + assert_equal "{\"age\":18}", @filter.jsonify({:age => 18}) + end + + should "convert array to json" do + assert_equal "[1,2]", @filter.jsonify([1, 2]) + assert_equal "[{\"name\":\"Jack\"},{\"name\":\"Smith\"}]", @filter.jsonify([{:name => 'Jack'}, {:name => 'Smith'}]) + end + end end end From 6c001f10ab8877aaa1c0b2c60d9dc5be9203095a Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 23 Oct 2013 09:40:39 -0500 Subject: [PATCH 031/133] Update history to reflect merge of #1557 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 00ef8a1f..195aad8e 100644 --- a/History.markdown +++ b/History.markdown @@ -4,6 +4,7 @@ * Add support for adding data as YAML files under a site's `_data` directory (#1003) * Allow variables to be used with `include` tags (#1495) + * Allow using gems for plugin management (#1557) ### Minor Enhancements * Decrease the specificity in the site template CSS (#1574) From 811b14412f86c045b8d4899aa16280e6111d5e65 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Wed, 23 Oct 2013 10:48:23 -0400 Subject: [PATCH 032/133] Add docs for new 'gems' option. --- site/docs/configuration.md | 1 + site/docs/plugins.md | 28 +++++++++++++++++++++++----- 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/site/docs/configuration.md b/site/docs/configuration.md index 31bf7048..c94656db 100644 --- a/site/docs/configuration.md +++ b/site/docs/configuration.md @@ -281,6 +281,7 @@ layouts: ./_layouts include: ['.htaccess'] exclude: [] keep_files: ['.git','.svn'] +gems: [] timezone: nil encoding: nil diff --git a/site/docs/plugins.md b/site/docs/plugins.md index a61d903e..c9e0c5ad 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -25,9 +25,27 @@ having to modify the Jekyll source itself. ## Installing a plugin -In your site source root, make a `_plugins` directory. Place your plugins here. -Any file ending in `*.rb` inside this directory will be loaded before Jekyll -generates your site. +You have 2 options for installing plugins: + +1. In your site source root, make a `_plugins` directory. Place your plugins here. + Any file ending in `*.rb` inside this directory will be loaded before Jekyll + generates your site. +2. In your `_config.yml` file, add a new array with the key `gems` and the values + of the gem names of the plugins you'd like to use. An example: + + gems: [jekyll-test-plugin, jekyll-jsonify, jekyll-assets] + # This will require each of these gems automatically. + +
+
+ _plugins and gems + can be used simultaneously +
+

+ You may use both of the aforementioned plugin options simultaneously in the + same site if you so choose. Use of one does not restrict the use of the other +

+
In general, plugins you make will fall into one of three categories: @@ -67,7 +85,7 @@ module Reading class Generator < Jekyll::Generator def generate(site) ongoing, done = Book.all.partition(&:ongoing?) - + reading = site.pages.detect {|page| page.name == 'reading.html'} reading.data['ongoing'] = ongoing reading.data['done'] = done @@ -394,7 +412,7 @@ You can find a few useful plugins at the following locations: - [ArchiveGenerator by Ilkka Laukkanen](https://gist.github.com/707909): Uses [this archive page](https://gist.github.com/707020) to generate archives. - [LESS.js Generator by Andy Fowler](https://gist.github.com/642739): Renders LESS.js files during generation. -- [Version Reporter by Blake Smith](https://gist.github.com/449491): Creates a version.html file containing the Jekyll version. +- [Version Reporter by Blake Smith](https://gist.github.com/449491): Creates a version.html file containing the Jekyll version. - [Sitemap.xml Generator by Michael Levin](https://github.com/kinnetica/jekyll-plugins): Generates a sitemap.xml file by traversing all of the available posts and pages. - [Full-text search by Pascal Widdershoven](https://github.com/PascalW/jekyll_indextank): Adds full-text search to your Jekyll site with a plugin and a bit of JavaScript. - [AliasGenerator by Thomas Mango](https://github.com/tsmango/jekyll_alias_generator): Generates redirect pages for posts when an alias is specified in the YAML Front Matter. From 32c7530ea6298d01b6d8c69a000f1f8989d67b4f Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 23 Oct 2013 22:37:41 -0500 Subject: [PATCH 033/133] Update history to reflect merge of #1656 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 195aad8e..4925b808 100644 --- a/History.markdown +++ b/History.markdown @@ -55,6 +55,7 @@ (#1614) * Add `jekyll-import` warning note of missing dependencies (#1626) * Fix grammar in the Usage section (#1635) + * Add documentation for the use of gems as plugins (#1656) ## 1.2.1 / 2013-09-14 From 2c11a6ec27d8416f806da96f500b61a192252b23 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 23 Oct 2013 22:47:01 -0500 Subject: [PATCH 034/133] Update history to reflect merge of #1589 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 4925b808..35614836 100644 --- a/History.markdown +++ b/History.markdown @@ -18,6 +18,7 @@ * Update Kramdown dependency to `~> 1.2` (#1610) * Update `safe_yaml` dependency to `~> 0.9.7` (#1602) * Allow layouts to be in subfolders like includes (#1622) + * Switch to listen for site watching while serving (#1589) ### Bug Fixes * Fix up matching against source and destination when the two From 2397a1665808864a4a33cb2cc2536c067201191e Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 23 Oct 2013 22:49:50 -0500 Subject: [PATCH 035/133] Update history to reflect merge of #1493 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 35614836..cd58a7c8 100644 --- a/History.markdown +++ b/History.markdown @@ -43,6 +43,7 @@ * Refactor Site#render (#1638) * Remove duplication in command line options (#1637) * Add tests for all the coderay options (#1543) + * Improve some of the cucumber test code (#1493) ### Site Enhancements * Fix params for `JekyllImport::WordPress.process` arguments (#1554) From 112aa8112d13901da1546d676ec005df35ac4a0e Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 23 Oct 2013 22:51:11 -0500 Subject: [PATCH 036/133] Update history to reflect merge of #1651 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index cd58a7c8..7bac23da 100644 --- a/History.markdown +++ b/History.markdown @@ -19,6 +19,7 @@ * Update `safe_yaml` dependency to `~> 0.9.7` (#1602) * Allow layouts to be in subfolders like includes (#1622) * Switch to listen for site watching while serving (#1589) + * Add a `json` liquid filter to be used in sites (#1651) ### Bug Fixes * Fix up matching against source and destination when the two From 9b40ae6b36f9f3be02bd5f63dcd1ec89782da6c4 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 23 Oct 2013 22:59:43 -0500 Subject: [PATCH 037/133] Update history to reflect merge of #1582 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 7bac23da..cf414077 100644 --- a/History.markdown +++ b/History.markdown @@ -45,6 +45,7 @@ * Remove duplication in command line options (#1637) * Add tests for all the coderay options (#1543) * Improve some of the cucumber test code (#1493) + * Improve comparisons of timestamps by ignoring the seconds (#1582) ### Site Enhancements * Fix params for `JekyllImport::WordPress.process` arguments (#1554) From ce0b8d2834d7dc470713dc10f4894064ef1f805f Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Thu, 24 Oct 2013 10:30:19 -0400 Subject: [PATCH 038/133] Change short version of '--verbose' to '-V' https://github.com/mojombo/jekyll/pull/1518 https://github.com/mojombo/jekyll/issues/1659 --- bin/jekyll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/jekyll b/bin/jekyll index d1aee02a..55af1b6a 100755 --- a/bin/jekyll +++ b/bin/jekyll @@ -40,7 +40,7 @@ def add_build_options(c) c.option '-w', '--watch', 'Watch for changes and rebuild' c.option '--lsi', 'Use LSI for improved related posts' c.option '-D', '--drafts', 'Render posts in the _drafts folder' - c.option '-v', '--verbose', 'Print verbose output.' + c.option '-V', '--verbose', 'Print verbose output.' end command :default do |c| From 727a705d67da70c8c64abbd785ce4449e1da8942 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Fri, 25 Oct 2013 10:00:05 -0500 Subject: [PATCH 039/133] Update history to reflect merge of #1660 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index cf414077..860a236c 100644 --- a/History.markdown +++ b/History.markdown @@ -30,6 +30,8 @@ * Downgrade to Maruku `~> 0.6.0` in order to avoid changes in rendering (#1598) * Fix error with failing include tag when variable was file name (#1613) * Downcase lexers before passing them to pygments (#1615) + * Capitalize the short verbose switch because it conflicts with the + built-in Commander switch (#1660) ### Development Fixes * Add coverage reporting with Coveralls (#1539) From 5bdb9eb0413ca5676c45c599e76f4578f9a77012 Mon Sep 17 00:00:00 2001 From: GSI2013 <2013@groovy-skills.com> Date: Sat, 26 Oct 2013 17:48:51 -0200 Subject: [PATCH 040/133] documented 'jekyll_date_chart', 'jekyll_image_encode' and 'jekyll_quick_man' in the plugins list --- site/docs/plugins.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/site/docs/plugins.md b/site/docs/plugins.md index c9e0c5ad..163a6f65 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -487,6 +487,9 @@ You can find a few useful plugins at the following locations: - [Ditaa Tag](https://github.com/matze/jekyll-ditaa) by [matze](https://github.com/matze): Renders ASCII diagram art into PNG images and inserts a figure tag. - [Good Include](https://github.com/penibelst/jekyll-good-include) by [Anatol Broder](http://penibelst.de/): Strips newlines and whitespaces from the end of include files before processing. - [Jekyll Suggested Tweet](https://github.com/davidensinger/jekyll-suggested-tweet) by [David Ensinger](https://github.com/davidensinger/): A Liquid tag for Jekyll that allows for the embedding of suggested tweets via Twitter’s Web Intents API. +- [Jekyll Date Chart](https://github.com/GSI/jekyll_date_chart) by [GSI](https://github.com/GSI): Block that renders date line charts based on textile-formatted tables. +- [Jekyll Image Encode](https://github.com/GSI/jekyll_image_encode) by [GSI](https://github.com/GSI): Tag that renders base64 codes of images fetched from the web. +- [Jekyll Quick Man](https://github.com/GSI/jekyll_quick_man) by [GSI](https://github.com/GSI): Tag that renders pretty links to man page sources on the internet. #### Collections From d14553cf75dc4313b3d319f95a654391224d5dd6 Mon Sep 17 00:00:00 2001 From: Anatol Broder Date: Sun, 27 Oct 2013 01:28:58 +0200 Subject: [PATCH 041/133] Change day example to a one-digit --- site/docs/templates.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/site/docs/templates.md b/site/docs/templates.md index 0417f2ab..c84eb827 100644 --- a/site/docs/templates.md +++ b/site/docs/templates.md @@ -33,7 +33,7 @@ common tasks easier. {% raw %}{{ site.time | date_to_xmlschema }}{% endraw %}

- 2008-11-17T13:07:54-08:00 + 2008-11-07T13:07:54-08:00

@@ -47,7 +47,7 @@ common tasks easier. {% raw %}{{ site.time | date_to_rfc822 }}{% endraw %}

- Mon, 17 Nov 2008 13:07:54 -0800 + Mon, 07 Nov 2008 13:07:54 -0800

@@ -61,7 +61,7 @@ common tasks easier. {% raw %}{{ site.time | date_to_string }}{% endraw %}

- 17 Nov 2008 + 07 Nov 2008

@@ -75,7 +75,7 @@ common tasks easier. {% raw %}{{ site.time | date_to_long_string }}{% endraw %}

- 17 November 2008 + 07 November 2008

From 6949006051ba8721c4d8c3fd73f35fd96b4a0d90 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sat, 26 Oct 2013 21:59:08 -0500 Subject: [PATCH 042/133] Update history to reflect merge of #1405 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 860a236c..dd1833d1 100644 --- a/History.markdown +++ b/History.markdown @@ -62,6 +62,7 @@ * Add `jekyll-import` warning note of missing dependencies (#1626) * Fix grammar in the Usage section (#1635) * Add documentation for the use of gems as plugins (#1656) + * Document the existence of a few additional plugins (#1405) ## 1.2.1 / 2013-09-14 From 71d4319d5f4353df0cdfa2df7791aa975428a1c5 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sat, 26 Oct 2013 22:08:38 -0500 Subject: [PATCH 043/133] Downgrade Listen to 1.3.x This is so that we can be Ruby 1.8.x compatible. --- jekyll.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jekyll.gemspec b/jekyll.gemspec index ab1ed585..b4d3483f 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -25,7 +25,7 @@ Gem::Specification.new do |s| s.add_runtime_dependency('liquid', "~> 2.5.2") s.add_runtime_dependency('classifier', "~> 1.3") - s.add_runtime_dependency('listen', "~> 2.0") + s.add_runtime_dependency('listen', "~> 1.3.0") s.add_runtime_dependency('maruku', "~> 0.6.0") s.add_runtime_dependency('pygments.rb', "~> 0.5.0") s.add_runtime_dependency('commander', "~> 4.1.3") From 1eb55119a30763217fc0d20a154e77179accbda2 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sat, 26 Oct 2013 22:11:10 -0500 Subject: [PATCH 044/133] Update history to reflect merge of #1663 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index dd1833d1..ad37616b 100644 --- a/History.markdown +++ b/History.markdown @@ -63,6 +63,8 @@ * Fix grammar in the Usage section (#1635) * Add documentation for the use of gems as plugins (#1656) * Document the existence of a few additional plugins (#1405) + * Document that the `date_to_string` always returns a two digit date + (#1663) ## 1.2.1 / 2013-09-14 From f0d0cbf947af3f1bc0fa2421a25cc5d4e0fdaea1 Mon Sep 17 00:00:00 2001 From: Carol Nichols Date: Sun, 27 Oct 2013 18:00:54 -0400 Subject: [PATCH 045/133] Referencing the documentation for jekyll-import installation Currently, there are only beta releases of the jekyll-import gem, so to install it, you have to do `gem install jekyll-import --pre`. Instead of giving instructions that don't work right now, reference the documentation. That way, this doesn't need to be updated again when jekyll-import has a non-beta version; just the documentation will need updating. --- bin/jekyll | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/bin/jekyll b/bin/jekyll index 55af1b6a..50d10e3a 100755 --- a/bin/jekyll +++ b/bin/jekyll @@ -149,8 +149,7 @@ command :import do |c| require 'jekyll-import' rescue LoadError msg = "You must install the 'jekyll-import' gem before continuing.\n" - msg += "* Do this by running `gem install jekyll-import`.\n" - msg += "* Or if you need root privileges, run `sudo gem install jekyll-import`." + msg += "* Please see the documentation at http://jekyllrb.com/docs/migrations/ for instructions.\n" abort msg end Jekyll::Commands::Import.process(args.first, options) From 3ab98412725b5f70d5f1811e9d532eff65f70fed Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 28 Oct 2013 14:03:34 -0400 Subject: [PATCH 046/133] Fix 1.8.7 syntax errors. --- lib/jekyll/commands/build.rb | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/lib/jekyll/commands/build.rb b/lib/jekyll/commands/build.rb index 56fe90e6..5948dd89 100644 --- a/lib/jekyll/commands/build.rb +++ b/lib/jekyll/commands/build.rb @@ -37,9 +37,8 @@ module Jekyll destination = options['destination'] begin - ignored = Regexp.new(Regexp.escape(Pathname.new(destination) - .relative_path_from(Pathname.new(source)) - .to_path)) + dest = Pathname.new(destination).relative_path_from(Pathname.new(source)).to_path + ignored = Regexp.new(Regexp.escape(dest)) rescue ArgumentError # Destination is outside the source, no need to ignore it. ignored = nil @@ -47,7 +46,7 @@ module Jekyll Jekyll.logger.info "Auto-regeneration:", "enabled" - listener = Listen.to(source, ignore: ignored) do |modified, added, removed| + listener = Listen.to(source, :ignore => ignored) do |modified, added, removed| t = Time.now.strftime("%Y-%m-%d %H:%M:%S") n = modified.length + added.length + removed.length print Jekyll.logger.formatted_topic("Regenerating:") + "#{n} files at #{t} " From a0a9c5f6764f70a6bd6bcd08d0718c614730a7ae Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 28 Oct 2013 14:04:37 -0400 Subject: [PATCH 047/133] Allow any versions of listen < 2.0 and >= 1.3 --- jekyll.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jekyll.gemspec b/jekyll.gemspec index b4d3483f..5754e2e7 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -25,7 +25,7 @@ Gem::Specification.new do |s| s.add_runtime_dependency('liquid', "~> 2.5.2") s.add_runtime_dependency('classifier', "~> 1.3") - s.add_runtime_dependency('listen', "~> 1.3.0") + s.add_runtime_dependency('listen', "~> 1.3") s.add_runtime_dependency('maruku', "~> 0.6.0") s.add_runtime_dependency('pygments.rb', "~> 0.5.0") s.add_runtime_dependency('commander', "~> 4.1.3") From 0c2d7c0864ae846caf4ee1cfb559158270b9253c Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 28 Oct 2013 14:16:06 -0400 Subject: [PATCH 048/133] Restrict mime-types gem to pre-2.0. A coveralls dep has a '>=' dependency on mime-types. --- jekyll.gemspec | 1 + 1 file changed, 1 insertion(+) diff --git a/jekyll.gemspec b/jekyll.gemspec index 5754e2e7..53882996 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -46,6 +46,7 @@ Gem::Specification.new do |s| s.add_development_dependency('simplecov', "~> 0.7") s.add_development_dependency('simplecov-gem-adapter', "~> 1.0.1") s.add_development_dependency('coveralls', "~> 0.7.0") + s.add_development_dependency('mime-types', "~> 1.5") s.add_development_dependency('activesupport', '~> 3.2.13') s.add_development_dependency('jekyll_test_plugin') From 08adcd4a3718c3db63e031ae05d00878998edd57 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Mon, 28 Oct 2013 14:36:25 -0500 Subject: [PATCH 049/133] Update history to reflect merge of #1665 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index ad37616b..4ddd4fe9 100644 --- a/History.markdown +++ b/History.markdown @@ -32,6 +32,7 @@ * Downcase lexers before passing them to pygments (#1615) * Capitalize the short verbose switch because it conflicts with the built-in Commander switch (#1660) + * Fix compatibility with 1.8.x (#1665) ### Development Fixes * Add coverage reporting with Coveralls (#1539) From 9f63ddb4dbb17a9fcf5838b0af98c5e2cd95f1d6 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Mon, 28 Oct 2013 20:26:36 -0500 Subject: [PATCH 050/133] Prepare for a 1.3.0.rc release --- jekyll.gemspec | 10 ++++++++-- lib/jekyll.rb | 2 +- ...3-10-28-jekyll-1-3-0-rc1-released.markdown | 19 +++++++++++++++++++ 3 files changed, 28 insertions(+), 3 deletions(-) create mode 100644 site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown diff --git a/jekyll.gemspec b/jekyll.gemspec index 53882996..35e15b33 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -4,9 +4,9 @@ Gem::Specification.new do |s| s.rubygems_version = '1.3.5' s.name = 'jekyll' - s.version = '1.2.1' + s.version = '1.3.0.rc' s.license = 'MIT' - s.date = '2013-09-14' + s.date = '2013-10-28' s.rubyforge_project = 'jekyll' s.summary = "A simple, blog aware, static site generator." @@ -160,6 +160,7 @@ Gem::Specification.new do |s| site/css/style.css site/docs/configuration.md site/docs/contributing.md + site/docs/datafiles.md site/docs/deployment-methods.md site/docs/drafts.md site/docs/extras.md @@ -206,10 +207,13 @@ Gem::Specification.new do |s| test/helper.rb test/source/+/foo.md test/source/.htaccess + test/source/_data/languages.yml test/source/_data/members.yaml + test/source/_data/products.yml test/source/_includes/params.html test/source/_includes/sig.markdown test/source/_layouts/default.html + test/source/_layouts/post/simple.html test/source/_layouts/simple.html test/source/_plugins/dummy.rb test/source/_posts/2008-02-02-not-published.textile @@ -255,7 +259,9 @@ Gem::Specification.new do |s| test/source/deal.with.dots.html test/source/foo/_posts/bar/2008-12-12-topical-post.textile test/source/index.html + test/source/products.yml test/source/sitemap.xml + test/source/symlink-test/_data test/source/symlink-test/symlinked-dir test/source/symlink-test/symlinked-file test/source/win/_posts/2009-05-24-yaml-linebreak.markdown diff --git a/lib/jekyll.rb b/lib/jekyll.rb index 1ad928bf..096c718f 100644 --- a/lib/jekyll.rb +++ b/lib/jekyll.rb @@ -61,7 +61,7 @@ require_all 'jekyll/tags' SafeYAML::OPTIONS[:suppress_warnings] = true module Jekyll - VERSION = '1.2.1' + VERSION = '1.3.0.rc' # Public: Generate a Jekyll configuration Hash by merging the default # options with anything in _config.yml, and adding the given options on top. diff --git a/site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown b/site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown new file mode 100644 index 00000000..f4f4852d --- /dev/null +++ b/site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown @@ -0,0 +1,19 @@ +--- +layout: news_item +title: 'Jekyll 1.3.0.rc1 Released' +date: 2013-10-28 20:14:39 -0500 +author: mattr- +version: 1.3.0.rc1 +categories: [release] +--- + +Jekyll 1.3.0 is going to be a big release! In order to make sure we +didn't screw anything up too badly, we're making a release candidate +available for any early adopters who want to give the latest and +greatest code a spin without having to clone a repository from git. + +Please take this prerelease for a spin and [let us +know](https://github.com/mojombo/jekyll/issues/new) if you run into any +issues! + + From 55f583da00cfab4d4501c8bb281b145f7b7eae29 Mon Sep 17 00:00:00 2001 From: albertogg Date: Mon, 28 Oct 2013 22:25:12 -0430 Subject: [PATCH 051/133] Add table_prefix option for jekyll-importer Add table_prefix to use with WordPress and Joomla importers so they can modify the default value. --- bin/jekyll | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/jekyll b/bin/jekyll index 55af1b6a..35ff8006 100755 --- a/bin/jekyll +++ b/bin/jekyll @@ -143,6 +143,7 @@ command :import do |c| c.option '--user STRING', 'Username to use when migrating' c.option '--pass STRING', 'Password to use when migrating' c.option '--host STRING', 'Host address to use when migrating' + c.option '--table_prefix STRING', 'Database table prefix to use when migrating' c.action do |args, options| begin From 1d72b1369f291b7fa135bf84ba5423603e8672c9 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Mon, 28 Oct 2013 22:37:31 -0500 Subject: [PATCH 052/133] Update history to reflect merge of #1662 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index 4ddd4fe9..2f61b29d 100644 --- a/History.markdown +++ b/History.markdown @@ -20,6 +20,8 @@ * Allow layouts to be in subfolders like includes (#1622) * Switch to listen for site watching while serving (#1589) * Add a `json` liquid filter to be used in sites (#1651) + * Point people to the migration docs when the `jekyll-import` gem is + missing (#1662) ### Bug Fixes * Fix up matching against source and destination when the two From 700fb7cb6d08a7f799078787a266f5f7b4a21358 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Mon, 28 Oct 2013 22:38:29 -0500 Subject: [PATCH 053/133] Fix a typo. --- History.markdown | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/History.markdown b/History.markdown index 2f61b29d..52b912e2 100644 --- a/History.markdown +++ b/History.markdown @@ -66,8 +66,7 @@ * Fix grammar in the Usage section (#1635) * Add documentation for the use of gems as plugins (#1656) * Document the existence of a few additional plugins (#1405) - * Document that the `date_to_string` always returns a two digit date - (#1663) + * Document that the `date_to_string` always returns a two digit day (#1663) ## 1.2.1 / 2013-09-14 From 1f0c139f35034cebc9da7cb4906cb5eacc59f330 Mon Sep 17 00:00:00 2001 From: Sam Rayner Date: Tue, 29 Oct 2013 09:33:55 +0000 Subject: [PATCH 054/133] Add Asset Path Tag to plugin list in docs Requested by @mattr- https://github.com/mojombo/jekyll/issues/881#issuecomment-27276509 --- site/docs/plugins.md | 1 + 1 file changed, 1 insertion(+) diff --git a/site/docs/plugins.md b/site/docs/plugins.md index 163a6f65..2e26f7ef 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -455,6 +455,7 @@ You can find a few useful plugins at the following locations: #### Tags +- [Asset Path Tag](https://github.com/samrayner/jekyll-asset-path-plugin) by [Sam Rayner](http://www.samrayner.com/): Allows organisation of assets into subdirectories by outputting a path for a given file relative to the current post or page. - [Delicious Plugin by Christian Hellsten](https://github.com/christianhellsten/jekyll-plugins): Fetches and renders bookmarks from delicious.com. - [Ultraviolet Plugin by Steve Alex](https://gist.github.com/480380): Jekyll tag for the [Ultraviolet](http://ultraviolet.rubyforge.org/) code highligher. - [Tag Cloud Plugin by Ilkka Laukkanen](https://gist.github.com/710577): Generate a tag cloud that links to tag pages. From a1fc0b18e8c1bf268ba363b25202b824971abbed Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Tue, 29 Oct 2013 12:31:02 -0400 Subject: [PATCH 055/133] Add Jekyll 1.3.0.rc1 Release Post to Gemspec --- jekyll.gemspec | 1 + 1 file changed, 1 insertion(+) diff --git a/jekyll.gemspec b/jekyll.gemspec index 35e15b33..d9aa1f14 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -154,6 +154,7 @@ Gem::Specification.new do |s| site/_posts/2013-07-25-jekyll-1-1-2-released.markdown site/_posts/2013-09-06-jekyll-1-2-0-released.markdown site/_posts/2013-09-14-jekyll-1-2-1-released.markdown + site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown site/css/gridism.css site/css/normalize.css site/css/pygments.css From 9fbcc5795b516aaa839706ba6bc2c2884a05db26 Mon Sep 17 00:00:00 2001 From: Yi Zeng Date: Wed, 30 Oct 2013 22:16:01 +1300 Subject: [PATCH 057/133] add missing section info to the drafts post, in order to make navigation links (Back, Next) work --- site/docs/drafts.md | 2 ++ site/docs/pages.md | 2 +- site/docs/posts.md | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/site/docs/drafts.md b/site/docs/drafts.md index e6455674..c921f2a5 100644 --- a/site/docs/drafts.md +++ b/site/docs/drafts.md @@ -1,6 +1,8 @@ --- layout: docs title: Working with drafts +prev_section: posts +next_section: pages permalink: /docs/drafts/ --- diff --git a/site/docs/pages.md b/site/docs/pages.md index 50388522..283c31cf 100644 --- a/site/docs/pages.md +++ b/site/docs/pages.md @@ -1,7 +1,7 @@ --- layout: docs title: Creating pages -prev_section: posts +prev_section: drafts next_section: variables permalink: /docs/pages/ --- diff --git a/site/docs/posts.md b/site/docs/posts.md index 3c57c217..88036bdb 100644 --- a/site/docs/posts.md +++ b/site/docs/posts.md @@ -2,7 +2,7 @@ layout: docs title: Writing posts prev_section: frontmatter -next_section: pages +next_section: drafts permalink: /docs/posts/ --- From ace1e0fc01b48c894c6392368f8c8d40ca82b15f Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 30 Oct 2013 07:44:06 -0500 Subject: [PATCH 058/133] Use the proper date in the gemspec --- jekyll.gemspec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jekyll.gemspec b/jekyll.gemspec index d9aa1f14..7034b251 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -6,7 +6,7 @@ Gem::Specification.new do |s| s.name = 'jekyll' s.version = '1.3.0.rc' s.license = 'MIT' - s.date = '2013-10-28' + s.date = '2013-10-29' s.rubyforge_project = 'jekyll' s.summary = "A simple, blog aware, static site generator." From aebda2b7d8b76eb28e7df3c8de0902339231a90a Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 30 Oct 2013 07:44:49 -0500 Subject: [PATCH 059/133] Update history to reflect merge of #1677 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 52b912e2..ca6de05d 100644 --- a/History.markdown +++ b/History.markdown @@ -67,6 +67,7 @@ * Add documentation for the use of gems as plugins (#1656) * Document the existence of a few additional plugins (#1405) * Document that the `date_to_string` always returns a two digit day (#1663) + * Fix navigation in the "Working with Drafts" page (#1667) ## 1.2.1 / 2013-09-14 From 7a1f63d9941bcc4b5b39052737c8fb514aa769de Mon Sep 17 00:00:00 2001 From: Jordon Bedwell Date: Thu, 31 Oct 2013 07:12:54 -0500 Subject: [PATCH 060/133] Sort plugins so people can have "load orders". This allows for people to do something like "_plugins/1-autoload-global.rb" and have it load first and so on making it much easier to organize code and have a "header file" that does all the requiring up front if it's needed for all plugins. --- lib/jekyll/site.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/site.rb b/lib/jekyll/site.rb index b892a31a..12ce1ae4 100644 --- a/lib/jekyll/site.rb +++ b/lib/jekyll/site.rb @@ -73,7 +73,7 @@ module Jekyll # directory. unless self.safe self.plugins.each do |plugins| - Dir[File.join(plugins, "**/*.rb")].each do |f| + Dir[File.join(plugins, "**/*.rb")].sort.each do |f| require f end end From 50fabc7b372aeea6ae56ead8a8d0e6be40d2dd11 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 1 Nov 2013 23:16:04 -0400 Subject: [PATCH 061/133] Update implementation of listen for v1.3.x --- lib/jekyll/commands/build.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/commands/build.rb b/lib/jekyll/commands/build.rb index 5948dd89..a0dd44e5 100644 --- a/lib/jekyll/commands/build.rb +++ b/lib/jekyll/commands/build.rb @@ -46,7 +46,7 @@ module Jekyll Jekyll.logger.info "Auto-regeneration:", "enabled" - listener = Listen.to(source, :ignore => ignored) do |modified, added, removed| + listener = Listen::Listener.new(source, :ignore => ignored) do |modified, added, removed| t = Time.now.strftime("%Y-%m-%d %H:%M:%S") n = modified.length + added.length + removed.length print Jekyll.logger.formatted_topic("Regenerating:") + "#{n} files at #{t} " From e70c71edd4d716f686702dd3f86f728206003a07 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Fri, 1 Nov 2013 22:56:05 -0500 Subject: [PATCH 062/133] Update history to reflect merge of #1687 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index ca6de05d..b71a460d 100644 --- a/History.markdown +++ b/History.markdown @@ -35,6 +35,8 @@ * Capitalize the short verbose switch because it conflicts with the built-in Commander switch (#1660) * Fix compatibility with 1.8.x (#1665) + * Fix an error with the new file watching code due to library version + incompatibilities (#1687) ### Development Fixes * Add coverage reporting with Coveralls (#1539) From 6c12955912824475da6ceeee726f4487ecd6e3a0 Mon Sep 17 00:00:00 2001 From: Katy DeCorah Date: Sun, 3 Nov 2013 10:27:47 -0500 Subject: [PATCH 063/133] updated end to endfor --- site/docs/datafiles.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/docs/datafiles.md b/site/docs/datafiles.md index c4e9e7e9..93b50aa3 100644 --- a/site/docs/datafiles.md +++ b/site/docs/datafiles.md @@ -57,7 +57,7 @@ You can now render the list of members in a template: {{ member.name }} -{% end %} +{% endfor %} {% endraw %} {% endhighlight %} From 3eed1cfed19c9fe771da0ca37e68a2ae23ffd759 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sun, 3 Nov 2013 09:55:54 -0600 Subject: [PATCH 064/133] Update history to reflect merge of #1691 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index b71a460d..e91008a5 100644 --- a/History.markdown +++ b/History.markdown @@ -70,6 +70,7 @@ * Document the existence of a few additional plugins (#1405) * Document that the `date_to_string` always returns a two digit day (#1663) * Fix navigation in the "Working with Drafts" page (#1667) + * Fix an error with the data documentation (#1691) ## 1.2.1 / 2013-09-14 From cc0c82f9d26ae00cac2d8326680761e366d4bde0 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sun, 3 Nov 2013 21:46:02 -0600 Subject: [PATCH 065/133] Prep for the 1.3.0 release --- History.markdown | 12 ++++++ jekyll.gemspec | 5 ++- .../2013-11-04-jekyll-1-3-0-released.markdown | 41 +++++++++++++++++++ 3 files changed, 56 insertions(+), 2 deletions(-) create mode 100644 site/_posts/2013-11-04-jekyll-1-3-0-released.markdown diff --git a/History.markdown b/History.markdown index e91008a5..1f5343ab 100644 --- a/History.markdown +++ b/History.markdown @@ -1,5 +1,17 @@ ## HEAD +### Major Enhancements + +### Minor Enhancements + +### Bug Fixes + +### Development Fixes + +### Site Enhancements + +## v1.3.0 / 2013-10-24 + ### Major Enhancements * Add support for adding data as YAML files under a site's `_data` directory (#1003) diff --git a/jekyll.gemspec b/jekyll.gemspec index 7034b251..62a866a6 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -4,9 +4,9 @@ Gem::Specification.new do |s| s.rubygems_version = '1.3.5' s.name = 'jekyll' - s.version = '1.3.0.rc' + s.version = '1.3.0' s.license = 'MIT' - s.date = '2013-10-29' + s.date = '2013-11-04' s.rubyforge_project = 'jekyll' s.summary = "A simple, blog aware, static site generator." @@ -155,6 +155,7 @@ Gem::Specification.new do |s| site/_posts/2013-09-06-jekyll-1-2-0-released.markdown site/_posts/2013-09-14-jekyll-1-2-1-released.markdown site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown + site/_posts/2013-11-04-jekyll-1-3-0-released.markdown site/css/gridism.css site/css/normalize.css site/css/pygments.css diff --git a/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown new file mode 100644 index 00000000..a1954979 --- /dev/null +++ b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown @@ -0,0 +1,41 @@ +--- +layout: news_item +title: 'Jekyll 1.3.0 Released' +date: 2013-10-23 23:15:22 -0500 +author: +version: 1.2.1 +categories: [release] +--- + +It's been about six weeks since v1.2.0 and the Jekyll team is happy to +announce the arrival of v1.3.0. This is a **huge** release full of all +sorts of new features, bug fixes, and other things that you're sure to +love. + +Here are a few things we think you'll want to know about this release: + +* You can add arbitrary data to the site by adding YAML files under a + site's `_data` directory. This will allow you to avoid + repetition in your templates and to set site specific options without + changing `_config.yml`. + +* You can now Run `jekyll serve --detach` to boot up a WEBrick server in the + background. **Note:** you'll need to run `kill [server_pid]` to shut + the server down. When ran, you'll get a process id that you can use in + place of `[server_pid]` + +* You can now **disable automatically-generated excerpts** if you set + `excerpt_separator` to `""`. + +* If you're moving pages and posts, you can now check for **URL + conflicts** by running `jekyll doctor`. + +* If you're a fan of the drafts feature, you'll be happy to know we've + added `-D`, a shortened version of `--drafts`. + +* Permalinks with special characters should now generate without errors. + +* Expose the current Jekyll version as the `jekyll.version` Liquid + variable. + +For a full run-down, visit our [change log](/docs/history/)! From 8987db896ec8abd0b98dfc9467cbaeea9d09d969 Mon Sep 17 00:00:00 2001 From: Shigeya Suzuki Date: Mon, 4 Nov 2013 12:46:18 +0900 Subject: [PATCH 066/133] Plugin description updates for Monthly/Category archive generator --- site/docs/plugins.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/site/docs/plugins.md b/site/docs/plugins.md index 163a6f65..d8b836c6 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -419,6 +419,8 @@ You can find a few useful plugins at the following locations: - [Pageless Redirect Generator by Nick Quinlan](https://github.com/nquinlan/jekyll-pageless-redirects): Generates redirects based on files in the Jekyll root, with support for htaccess style redirects. - [Projectlist by Frederic Hemberger](https://github.com/fhemberger/jekyll-projectlist): Renders files in a directory as a single page instead of separate posts. - [RssGenerator by Assaf Gelber](https://github.com/agelber/jekyll-rss): Automatically creates an RSS 2.0 feed from your posts. +- [Monthly archive generator by Shigeya Suzuki](https://github.com/shigeya/jekyll-monthly-archive-plugin): Generator and template which renders monthly archive like MovableType style, based on the work by Ilkka Laukkanen and others above. +- [Category archive generator by Shigeya Suzuki](https://github.com/shigeya/jekyll-category-archive-plugin): Generator and template which renders category archive like MovableType style, based on Monthly archive generator. #### Converters From 65653fed849db5075dadaab9a5fabafd01cb5e71 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sun, 3 Nov 2013 21:48:34 -0600 Subject: [PATCH 067/133] Bump version to 1.3.0 --- lib/jekyll.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll.rb b/lib/jekyll.rb index 096c718f..d99a3972 100644 --- a/lib/jekyll.rb +++ b/lib/jekyll.rb @@ -61,7 +61,7 @@ require_all 'jekyll/tags' SafeYAML::OPTIONS[:suppress_warnings] = true module Jekyll - VERSION = '1.3.0.rc' + VERSION = '1.3.0' # Public: Generate a Jekyll configuration Hash by merging the default # options with anything in _config.yml, and adding the given options on top. From b5437a49fbd43d13c4e64608f6663710f6f52e74 Mon Sep 17 00:00:00 2001 From: Santeri Paavolainen Date: Mon, 4 Nov 2013 19:10:25 +0200 Subject: [PATCH 068/133] Updated docs to match reality, where drafts are dated based on file modification time See https://github.com/mojombo/jekyll/blob/8e7b6bf5ff56e6bb8d0f1019c19b351f1d600e39/lib/jekyll/draft.rb#L28 -- source uses `File.mtime` on the draft file, not `Time.now` as the doc says. --- site/docs/drafts.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/site/docs/drafts.md b/site/docs/drafts.md index c921f2a5..959964d0 100644 --- a/site/docs/drafts.md +++ b/site/docs/drafts.md @@ -17,6 +17,5 @@ first draft: {% endhighlight %} To preview your site with drafts, simply run `jekyll serve` or `jekyll build` with -the `--drafts` switch. Each will be assigned the value of `Time.now` -for its date, and thus you will see them generated as the latest posts. - +the `--drafts` switch. Each will be assigned the value modification time of the draft file +for its date, and thus you will see currently edited drafts as the latest posts. From a49a0ec2ac12d883b5d1a7e95eed78275eb9a2af Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 4 Nov 2013 14:39:56 -0500 Subject: [PATCH 069/133] Minor fixes to v1.3.0 release post. --- site/_posts/2013-11-04-jekyll-1-3-0-released.markdown | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown index a1954979..e14ea119 100644 --- a/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown +++ b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown @@ -1,9 +1,9 @@ --- layout: news_item title: 'Jekyll 1.3.0 Released' -date: 2013-10-23 23:15:22 -0500 -author: -version: 1.2.1 +date: 2013-11-04 21:46:02 -0600 +author: mattr- +version: 1.3.0 categories: [release] --- @@ -14,7 +14,7 @@ love. Here are a few things we think you'll want to know about this release: -* You can add arbitrary data to the site by adding YAML files under a +* You can add [arbitrary data][] to the site by adding YAML files under a site's `_data` directory. This will allow you to avoid repetition in your templates and to set site specific options without changing `_config.yml`. @@ -39,3 +39,5 @@ Here are a few things we think you'll want to know about this release: variable. For a full run-down, visit our [change log](/docs/history/)! + +[arbitrary docs]: /docs/datafiles/ From b9817ab47b3aea2735bcaf9480fbab51fa3a09e2 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 4 Nov 2013 14:40:53 -0500 Subject: [PATCH 070/133] Fix release date of v1.3.0 in History file --- History.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/History.markdown b/History.markdown index 1f5343ab..160aff33 100644 --- a/History.markdown +++ b/History.markdown @@ -10,7 +10,7 @@ ### Site Enhancements -## v1.3.0 / 2013-10-24 +## v1.3.0 / 2013-11-04 ### Major Enhancements * Add support for adding data as YAML files under a site's `_data` From 2087fb87b2470836252f2e0697dfd5038ecaab6a Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 4 Nov 2013 14:43:27 -0500 Subject: [PATCH 071/133] Fix link to /docs/datafiles/ in 1.3.0 release post. --- site/_posts/2013-11-04-jekyll-1-3-0-released.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown index e14ea119..2cddd5e6 100644 --- a/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown +++ b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown @@ -40,4 +40,4 @@ Here are a few things we think you'll want to know about this release: For a full run-down, visit our [change log](/docs/history/)! -[arbitrary docs]: /docs/datafiles/ +[arbitrary data]: /docs/datafiles/ From 5d672782fb5a64c370871cbb4fecc37663e43cd8 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 4 Nov 2013 21:07:51 -0500 Subject: [PATCH 074/133] Update jekyllrb.com site history. --- History.markdown | 2 +- site/docs/history.md | 74 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 75 insertions(+), 1 deletion(-) diff --git a/History.markdown b/History.markdown index 160aff33..dfa841aa 100644 --- a/History.markdown +++ b/History.markdown @@ -10,7 +10,7 @@ ### Site Enhancements -## v1.3.0 / 2013-11-04 +## 1.3.0 / 2013-11-04 ### Major Enhancements * Add support for adding data as YAML files under a site's `_data` diff --git a/site/docs/history.md b/site/docs/history.md index 1b2e7ffc..3e2d051c 100644 --- a/site/docs/history.md +++ b/site/docs/history.md @@ -5,6 +5,80 @@ permalink: /docs/history/ prev_section: contributing --- +## 1.3.0 / 2013-11-04 + +### Major Enhancements +- Add support for adding data as YAML files under a site's `_data` + directory ([#1003]({{ site.repository }}/issues/1003)) +- Allow variables to be used with `include` tags ([#1495]({{ site.repository }}/issues/1495)) +- Allow using gems for plugin management ([#1557]({{ site.repository }}/issues/1557)) + +### Minor Enhancements +- Decrease the specificity in the site template CSS ([#1574]({{ site.repository }}/issues/1574)) +- Add `encoding` configuration option ([#1449]({{ site.repository }}/issues/1449)) +- Provide better error handling for Jekyll's custom Liquid tags + ([#1514]({{ site.repository }}/issues/1514)) +- If an included file causes a Liquid error, add the path to the + include file that caused the error to the error message ([#1596]({{ site.repository }}/issues/1596)) +- If a layout causes a Liquid error, change the error message so that + we know it comes from the layout ([#1601]({{ site.repository }}/issues/1601)) +- Update Kramdown dependency to `~> 1.2` ([#1610]({{ site.repository }}/issues/1610)) +- Update `safe_yaml` dependency to `~> 0.9.7` ([#1602]({{ site.repository }}/issues/1602)) +- Allow layouts to be in subfolders like includes ([#1622]({{ site.repository }}/issues/1622)) +- Switch to listen for site watching while serving ([#1589]({{ site.repository }}/issues/1589)) +- Add a `json` liquid filter to be used in sites ([#1651]({{ site.repository }}/issues/1651)) +- Point people to the migration docs when the `jekyll-import` gem is + missing ([#1662]({{ site.repository }}/issues/1662)) + +### Bug Fixes +- Fix up matching against source and destination when the two + locations are similar ([#1556]({{ site.repository }}/issues/1556)) +- Fix the missing `pathname` require in certain cases ([#1255]({{ site.repository }}/issues/1255)) +- Use `+` instead of `Array#concat` when building `Post` attribute list ([#1571]({{ site.repository }}/issues/1571)) +- Print server address when launching a server ([#1586]({{ site.repository }}/issues/1586)) +- Downgrade to Maruku `~> 0.6.0` in order to avoid changes in rendering ([#1598]({{ site.repository }}/issues/1598)) +- Fix error with failing include tag when variable was file name ([#1613]({{ site.repository }}/issues/1613)) +- Downcase lexers before passing them to pygments ([#1615]({{ site.repository }}/issues/1615)) +- Capitalize the short verbose switch because it conflicts with the + built-in Commander switch ([#1660]({{ site.repository }}/issues/1660)) +- Fix compatibility with 1.8.x ([#1665]({{ site.repository }}/issues/1665)) +- Fix an error with the new file watching code due to library version + incompatibilities ([#1687]({{ site.repository }}/issues/1687)) + +### Development Fixes +- Add coverage reporting with Coveralls ([#1539]({{ site.repository }}/issues/1539)) +- Refactor the Liquid `include` tag ([#1490]({{ site.repository }}/issues/1490)) +- Update launchy dependency to `~> 2.3` ([#1608]({{ site.repository }}/issues/1608)) +- Update rr dependency to `~> 1.1` ([#1604]({{ site.repository }}/issues/1604)) +- Update cucumber dependency to `~> 1.3` ([#1607]({{ site.repository }}/issues/1607)) +- Update coveralls dependency to `~> 0.7.0` ([#1606]({{ site.repository }}/issues/1606)) +- Update rake dependency to `~> 10.1` ([#1603]({{ site.repository }}/issues/1603)) +- Clean up `site.rb` comments to be more concise/uniform ([#1616]({{ site.repository }}/issues/1616)) +- Use the master branch for the build badge in the readme ([#1636]({{ site.repository }}/issues/1636)) +- Refactor Site#render ([#1638]({{ site.repository }}/issues/1638)) +- Remove duplication in command line options ([#1637]({{ site.repository }}/issues/1637)) +- Add tests for all the coderay options ([#1543]({{ site.repository }}/issues/1543)) +- Improve some of the cucumber test code ([#1493]({{ site.repository }}/issues/1493)) +- Improve comparisons of timestamps by ignoring the seconds ([#1582]({{ site.repository }}/issues/1582)) + +### Site Enhancements +- Fix params for `JekyllImport::WordPress.process` arguments ([#1554]({{ site.repository }}/issues/1554)) +- Add `jekyll-suggested-tweet` to list of third-party plugins ([#1555]({{ site.repository }}/issues/1555)) +- Link to Liquid's docs for tags and filters ([#1553]({{ site.repository }}/issues/1553)) +- Add note about installing Xcode on the Mac in the Installation docs ([#1561]({{ site.repository }}/issues/1561)) +- Simplify/generalize pagination docs ([#1577]({{ site.repository }}/issues/1577)) +- Add documentation for the new data sources feature ([#1503]({{ site.repository }}/issues/1503)) +- Add more information on how to create generators ([#1590]({{ site.repository }}/issues/1590), [#1592]({{ site.repository }}/issues/1592)) +- Improve the instructions for mimicking GitHub Flavored Markdown + ([#1614]({{ site.repository }}/issues/1614)) +- Add `jekyll-import` warning note of missing dependencies ([#1626]({{ site.repository }}/issues/1626)) +- Fix grammar in the Usage section ([#1635]({{ site.repository }}/issues/1635)) +- Add documentation for the use of gems as plugins ([#1656]({{ site.repository }}/issues/1656)) +- Document the existence of a few additional plugins ([#1405]({{ site.repository }}/issues/1405)) +- Document that the `date_to_string` always returns a two digit day ([#1663]({{ site.repository }}/issues/1663)) +- Fix navigation in the "Working with Drafts" page ([#1667]({{ site.repository }}/issues/1667)) +- Fix an error with the data documentation ([#1691]({{ site.repository }}/issues/1691)) + ## 1.2.1 / 2013-09-14 ### Minor Enhancements From 63713799cdcba655c94e227d956400a456499859 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Mon, 4 Nov 2013 21:32:09 -0600 Subject: [PATCH 075/133] Extract Site#filter_entries into its own class --- lib/jekyll.rb | 1 + lib/jekyll/entry_filter.rb | 35 ++++++++++++++++++ test/test_entry_filter.rb | 74 ++++++++++++++++++++++++++++++++++++++ test/test_site.rb | 63 -------------------------------- 4 files changed, 110 insertions(+), 63 deletions(-) create mode 100644 lib/jekyll/entry_filter.rb create mode 100644 test/test_entry_filter.rb diff --git a/lib/jekyll.rb b/lib/jekyll.rb index d99a3972..f9f787b7 100644 --- a/lib/jekyll.rb +++ b/lib/jekyll.rb @@ -45,6 +45,7 @@ require 'jekyll/static_file' require 'jekyll/errors' require 'jekyll/related_posts' require 'jekyll/cleaner' +require 'jekyll/entry_filter' # extensions require 'jekyll/plugin' diff --git a/lib/jekyll/entry_filter.rb b/lib/jekyll/entry_filter.rb new file mode 100644 index 00000000..56f3cfc2 --- /dev/null +++ b/lib/jekyll/entry_filter.rb @@ -0,0 +1,35 @@ +class EntryFilter + attr_reader :site + def initialize(site) + @site = site + end + + def filter(entries) + entries.reject do |e| + unless included?(e) + special?(e) || backup?(e) || excluded?(e) || symlink?(e) + end + end + end + + def included?(entry) + site.include.glob_include?(entry) + end + + def special?(entry) + ['.', '_', '#'].include?(entry[0..0]) + end + + def backup?(entry) + entry[-1..-1] == '~' + end + + def excluded?(entry) + site.exclude.glob_include?(entry) + end + + def symlink?(entry) + File.symlink?(entry) && site.safe + end + +end diff --git a/test/test_entry_filter.rb b/test/test_entry_filter.rb new file mode 100644 index 00000000..c295a57c --- /dev/null +++ b/test/test_entry_filter.rb @@ -0,0 +1,74 @@ +require 'helper' + +class TestEntryFilter < Test::Unit::TestCase + context "Filtering entries" do + setup do + stub(Jekyll).configuration do + Jekyll::Configuration::DEFAULTS.merge({'source' => source_dir, 'destination' => dest_dir}) + end + @site = Site.new(Jekyll.configuration) + end + + should "filter entries" do + ent1 = %w[foo.markdown bar.markdown baz.markdown #baz.markdown# + .baz.markdow foo.markdown~ .htaccess _posts _pages] + + entries = EntryFilter.new(@site).filter(ent1) + assert_equal %w[foo.markdown bar.markdown baz.markdown .htaccess], entries + end + + should "filter entries with exclude" do + excludes = %w[README TODO] + files = %w[index.html site.css .htaccess] + + @site.exclude = excludes + ["exclude*"] + assert_equal files, @site.filter_entries(excludes + files + ["excludeA"]) + end + + should "not filter entries within include" do + includes = %w[_index.html .htaccess include*] + files = %w[index.html _index.html .htaccess includeA] + + @site.include = includes + assert_equal files, @site.filter_entries(files) + end + + should "filter symlink entries when safe mode enabled" do + stub(Jekyll).configuration do + Jekyll::Configuration::DEFAULTS.merge({'source' => source_dir, 'destination' => dest_dir, 'safe' => true}) + end + site = Site.new(Jekyll.configuration) + stub(File).symlink?('symlink.js') {true} + files = %w[symlink.js] + assert_equal [], site.filter_entries(files) + end + + should "not filter symlink entries when safe mode disabled" do + stub(File).symlink?('symlink.js') {true} + files = %w[symlink.js] + assert_equal files, @site.filter_entries(files) + end + + should "not include symlinks in safe mode" do + stub(Jekyll).configuration do + Jekyll::Configuration::DEFAULTS.merge({'source' => source_dir, 'destination' => dest_dir, 'safe' => true}) + end + site = Site.new(Jekyll.configuration) + + site.read_directories("symlink-test") + assert_equal [], site.pages + assert_equal [], site.static_files + end + + should "include symlinks in unsafe mode" do + stub(Jekyll).configuration do + Jekyll::Configuration::DEFAULTS.merge({'source' => source_dir, 'destination' => dest_dir, 'safe' => false}) + end + site = Site.new(Jekyll.configuration) + + site.read_directories("symlink-test") + assert_not_equal [], site.pages + assert_not_equal [], site.static_files + end + end +end diff --git a/test/test_site.rb b/test/test_site.rb index 4deb5645..35359a2a 100644 --- a/test/test_site.rb +++ b/test/test_site.rb @@ -179,69 +179,6 @@ class TestSite < Test::Unit::TestCase assert_equal 4, @site.categories['foo'].size end - should "filter entries" do - ent1 = %w[foo.markdown bar.markdown baz.markdown #baz.markdown# - .baz.markdow foo.markdown~] - ent2 = %w[.htaccess _posts _pages bla.bla] - - assert_equal %w[foo.markdown bar.markdown baz.markdown], @site.filter_entries(ent1) - assert_equal %w[.htaccess bla.bla], @site.filter_entries(ent2) - end - - should "filter entries with exclude" do - excludes = %w[README TODO] - files = %w[index.html site.css .htaccess] - - @site.exclude = excludes + ["exclude*"] - assert_equal files, @site.filter_entries(excludes + files + ["excludeA"]) - end - - should "not filter entries within include" do - includes = %w[_index.html .htaccess include*] - files = %w[index.html _index.html .htaccess includeA] - - @site.include = includes - assert_equal files, @site.filter_entries(files) - end - - should "filter symlink entries when safe mode enabled" do - stub(Jekyll).configuration do - Jekyll::Configuration::DEFAULTS.merge({'source' => source_dir, 'destination' => dest_dir, 'safe' => true}) - end - site = Site.new(Jekyll.configuration) - stub(File).symlink?('symlink.js') {true} - files = %w[symlink.js] - assert_equal [], site.filter_entries(files) - end - - should "not filter symlink entries when safe mode disabled" do - stub(File).symlink?('symlink.js') {true} - files = %w[symlink.js] - assert_equal files, @site.filter_entries(files) - end - - should "not include symlinks in safe mode" do - stub(Jekyll).configuration do - Jekyll::Configuration::DEFAULTS.merge({'source' => source_dir, 'destination' => dest_dir, 'safe' => true}) - end - site = Site.new(Jekyll.configuration) - - site.read_directories("symlink-test") - assert_equal [], site.pages - assert_equal [], site.static_files - end - - should "include symlinks in unsafe mode" do - stub(Jekyll).configuration do - Jekyll::Configuration::DEFAULTS.merge({'source' => source_dir, 'destination' => dest_dir, 'safe' => false}) - end - site = Site.new(Jekyll.configuration) - - site.read_directories("symlink-test") - assert_not_equal [], site.pages - assert_not_equal [], site.static_files - end - context 'error handling' do should "raise if destination is included in source" do stub(Jekyll).configuration do From 6791f9fc129c823ae2ec2fd4b79d807008e945e9 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Mon, 4 Nov 2013 21:35:53 -0600 Subject: [PATCH 076/133] Use the new `EntryFilter` class in `Site` --- lib/jekyll/site.rb | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/lib/jekyll/site.rb b/lib/jekyll/site.rb index b892a31a..b0dcbb06 100644 --- a/lib/jekyll/site.rb +++ b/lib/jekyll/site.rb @@ -325,14 +325,7 @@ module Jekyll # # Returns the Array of filtered entries. def filter_entries(entries) - entries.reject do |e| - unless self.include.glob_include?(e) - ['.', '_', '#'].include?(e[0..0]) || - e[-1..-1] == '~' || - self.exclude.glob_include?(e) || - (File.symlink?(e) && self.safe) - end - end + EntryFilter.new(self).filter(entries) end # Get the implementation class for the given Converter. From 2b851be9bd73b66c189aebc4561e12f2a2041543 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 4 Nov 2013 23:15:29 -0500 Subject: [PATCH 077/133] Update history to reflect merge of #1693 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index dfa841aa..7e7a3563 100644 --- a/History.markdown +++ b/History.markdown @@ -9,6 +9,8 @@ ### Development Fixes ### Site Enhancements + * Add `jekyll-monthly-archive-plugin` and `jekyll-category-archive-plugin` to + list of third-party plugins (#1693) ## 1.3.0 / 2013-11-04 From 93bd11ea05cede66c3451d6992b7e78275198e52 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 4 Nov 2013 23:16:49 -0500 Subject: [PATCH 078/133] Update history to reflect merge of #1695 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index 7e7a3563..019a9ad8 100644 --- a/History.markdown +++ b/History.markdown @@ -9,6 +9,8 @@ ### Development Fixes ### Site Enhancements + * Fix drafts docs to indicate that draft time is based on file modification + time, not `Time.now` (#1695) * Add `jekyll-monthly-archive-plugin` and `jekyll-category-archive-plugin` to list of third-party plugins (#1693) From a26663fb3618df8b2a028f00434938ce75aa3dc2 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 4 Nov 2013 23:21:40 -0500 Subject: [PATCH 079/133] Update history to reflect merge of #1670 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 019a9ad8..78c6d5b4 100644 --- a/History.markdown +++ b/History.markdown @@ -13,6 +13,7 @@ time, not `Time.now` (#1695) * Add `jekyll-monthly-archive-plugin` and `jekyll-category-archive-plugin` to list of third-party plugins (#1693) + * Add `jekyll-asset-path-plugin` to list of third-party plugins (#1670) ## 1.3.0 / 2013-11-04 From 0a0acaad370d704a309dfd0f2307a1ee463a0803 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Tue, 5 Nov 2013 07:45:44 -0600 Subject: [PATCH 080/133] Update history to reflect merge of #1697 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 78c6d5b4..b158949f 100644 --- a/History.markdown +++ b/History.markdown @@ -7,6 +7,7 @@ ### Bug Fixes ### Development Fixes + * Extract `Site#filter_entries` into its own object (#1697) ### Site Enhancements * Fix drafts docs to indicate that draft time is based on file modification From 41b2000129edb32709ba2e64743c276d86fe90ba Mon Sep 17 00:00:00 2001 From: albertogg Date: Wed, 6 Nov 2013 19:14:39 -0500 Subject: [PATCH 081/133] Use prefix instead of table_prefix. --- bin/jekyll | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/jekyll b/bin/jekyll index 35ff8006..3ae3028e 100755 --- a/bin/jekyll +++ b/bin/jekyll @@ -143,7 +143,7 @@ command :import do |c| c.option '--user STRING', 'Username to use when migrating' c.option '--pass STRING', 'Password to use when migrating' c.option '--host STRING', 'Host address to use when migrating' - c.option '--table_prefix STRING', 'Database table prefix to use when migrating' + c.option '--prefix STRING', 'Database table prefix to use when migrating' c.action do |args, options| begin From 1defcad9a3e093df449527d41ec0505a0650d0fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andreas=20M=C3=B6ller?= Date: Fri, 8 Nov 2013 08:40:19 +0100 Subject: [PATCH 082/133] Fix link to previous section There's no `assets` section. Linking to `pagination` instead. --- site/docs/plugins.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/docs/plugins.md b/site/docs/plugins.md index ef588610..2429a416 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -1,7 +1,7 @@ --- layout: docs title: Plugins -prev_section: assets +prev_section: pagination next_section: extras permalink: /docs/plugins/ --- From eeecbdc82a56c6103f98040158d7ae0f28cb13e5 Mon Sep 17 00:00:00 2001 From: Yihang Ho Date: Fri, 8 Nov 2013 17:36:07 +0800 Subject: [PATCH 083/133] Add Emoji for Jekyll to plugin list. --- site/docs/plugins.md | 1 + 1 file changed, 1 insertion(+) diff --git a/site/docs/plugins.md b/site/docs/plugins.md index ef588610..2580ea32 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -421,6 +421,7 @@ You can find a few useful plugins at the following locations: - [RssGenerator by Assaf Gelber](https://github.com/agelber/jekyll-rss): Automatically creates an RSS 2.0 feed from your posts. - [Monthly archive generator by Shigeya Suzuki](https://github.com/shigeya/jekyll-monthly-archive-plugin): Generator and template which renders monthly archive like MovableType style, based on the work by Ilkka Laukkanen and others above. - [Category archive generator by Shigeya Suzuki](https://github.com/shigeya/jekyll-category-archive-plugin): Generator and template which renders category archive like MovableType style, based on Monthly archive generator. +- [Emoji for Jekyll](https://github.com/yihangho/emoji-for-jekyll): Seamlessly enable emoji for all posts and pages. #### Converters From 0819877701eb9973203d95d936597431f9b9eb00 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 8 Nov 2013 14:28:48 -0500 Subject: [PATCH 084/133] Update history to reflect merge of #1708 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index b158949f..be8d62e2 100644 --- a/History.markdown +++ b/History.markdown @@ -15,6 +15,7 @@ * Add `jekyll-monthly-archive-plugin` and `jekyll-category-archive-plugin` to list of third-party plugins (#1693) * Add `jekyll-asset-path-plugin` to list of third-party plugins (#1670) + * Add `emoji-for-jekyll` to list of third-part plugins (#1708) ## 1.3.0 / 2013-11-04 From 0a359b586d26fe731ef4686174e9506162802b7b Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 8 Nov 2013 14:34:33 -0500 Subject: [PATCH 085/133] Update history to reflect merge of #1707 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index be8d62e2..62f75278 100644 --- a/History.markdown +++ b/History.markdown @@ -16,6 +16,7 @@ list of third-party plugins (#1693) * Add `jekyll-asset-path-plugin` to list of third-party plugins (#1670) * Add `emoji-for-jekyll` to list of third-part plugins (#1708) + * Fix previous section link on plugins page to point to pagination page (#1707) ## 1.3.0 / 2013-11-04 From 4e38d4858c45d9df0f2139718b2625b9e1f17814 Mon Sep 17 00:00:00 2001 From: Abhi Yerra Date: Fri, 8 Nov 2013 13:09:40 -0800 Subject: [PATCH 086/133] Link to an org-mode converter for Jekyll --- site/docs/plugins.md | 1 + 1 file changed, 1 insertion(+) diff --git a/site/docs/plugins.md b/site/docs/plugins.md index ace987aa..eb6392f4 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -440,6 +440,7 @@ You can find a few useful plugins at the following locations: - [Jekyll-pandoc-multiple-formats](https://github.com/fauno/jekyll-pandoc-multiple-formats) by [edsl](https://github.com/edsl): Use pandoc to generate your site in multiple formats. Supports pandoc’s markdown extensions. - [ReStructuredText Converter](https://github.com/xdissent/jekyll-rst): Converts ReST documents to HTML with Pygments syntax highlighting. - [Transform Layouts](https://gist.github.com/1472645): Allows HAML layouts (you need a HAML Converter plugin for this to work). +- [Org-mode Converter](https://gist.github.com/abhiyerra/7377603): Org-mode converter for Jekyll. #### Filters From 861f367de7549ab205dd283c5049e192f80a58f1 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 8 Nov 2013 23:16:36 -0500 Subject: [PATCH 087/133] Update history to reflect merge of #1711 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 62f75278..c453177b 100644 --- a/History.markdown +++ b/History.markdown @@ -17,6 +17,7 @@ * Add `jekyll-asset-path-plugin` to list of third-party plugins (#1670) * Add `emoji-for-jekyll` to list of third-part plugins (#1708) * Fix previous section link on plugins page to point to pagination page (#1707) + * Add `org-mode` converter plugin to third-party plugins (#1711) ## 1.3.0 / 2013-11-04 From 6842148389cb53bfc38d4557af81100fdd4c30a9 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sun, 10 Nov 2013 21:45:47 -0600 Subject: [PATCH 088/133] Update history to reflect merge of #1669 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index c453177b..3673ccd2 100644 --- a/History.markdown +++ b/History.markdown @@ -3,6 +3,7 @@ ### Major Enhancements ### Minor Enhancements + * Add a `--prefix` option to passthrough for the importers (#1669) ### Bug Fixes From 839f23102768de8d42a0192160e91cd0ced3065a Mon Sep 17 00:00:00 2001 From: Anatol Broder Date: Fri, 23 Aug 2013 22:59:10 +0200 Subject: [PATCH 089/133] Replace yoursite.com by example.com --- CONTRIBUTING.markdown | 5 ++++- site/docs/pages.md | 12 ++++++------ 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/CONTRIBUTING.markdown b/CONTRIBUTING.markdown index 6df99625..7831eb48 100644 --- a/CONTRIBUTING.markdown +++ b/CONTRIBUTING.markdown @@ -68,7 +68,10 @@ You can find the documentation for jekyllrb.com in the Jekyll's repo on GitHub.com. All documentation pull requests should be directed at `master`. Pull -requests directed at another branch will not be accepted. +requests directed at another branch will not be accepted. + +Use the domain `example.com` as an example in order to comply with the +[RFC 2606](http://tools.ietf.org/html/rfc2606). The [Jekyll wiki](https://github.com/mojombo/jekyll/wiki) on GitHub can be freely updated without a pull request as all GitHub users have access. diff --git a/site/docs/pages.md b/site/docs/pages.md index 283c31cf..e7b837fa 100644 --- a/site/docs/pages.md +++ b/site/docs/pages.md @@ -53,9 +53,9 @@ and associated URLs might look like: |-- _layouts/ |-- _posts/ |-- _site/ -|-- about.html # => http://yoursite.com/about.html -|-- index.html # => http://yoursite.com/ -└── contact.html # => http://yoursite.com/contact.html +|-- about.html # => http://example.com/about.html +|-- index.html # => http://example.com/ +└── contact.html # => http://example.com/contact.html {% endhighlight %} ### Named folders containing index HTML files @@ -76,10 +76,10 @@ look like: ├── _posts/ ├── _site/ ├── about/ -| └── index.html # => http://yoursite.com/about/ +| └── index.html # => http://example.com/about/ ├── contact/ -| └── index.html # => http://yoursite.com/contact/ -└── index.html # => http://yoursite.com/ +| └── index.html # => http://example.com/contact/ +└── index.html # => http://example.com/ {% endhighlight %} This approach may not suit everyone, but for people who like clean URLs it’s From 9291ca7492669e794092b5a9a17620bafc9a6d00 Mon Sep 17 00:00:00 2001 From: Anatol Broder Date: Sat, 24 Aug 2013 18:23:14 +0200 Subject: [PATCH 090/133] Revert hint --- CONTRIBUTING.markdown | 3 --- 1 file changed, 3 deletions(-) diff --git a/CONTRIBUTING.markdown b/CONTRIBUTING.markdown index 7831eb48..88c0ced5 100644 --- a/CONTRIBUTING.markdown +++ b/CONTRIBUTING.markdown @@ -70,9 +70,6 @@ Jekyll's repo on GitHub.com. All documentation pull requests should be directed at `master`. Pull requests directed at another branch will not be accepted. -Use the domain `example.com` as an example in order to comply with the -[RFC 2606](http://tools.ietf.org/html/rfc2606). - The [Jekyll wiki](https://github.com/mojombo/jekyll/wiki) on GitHub can be freely updated without a pull request as all GitHub users have access. From 29ef18828aff65295ad145714a9b9ec6dae0ff4f Mon Sep 17 00:00:00 2001 From: Anatol Broder Date: Sat, 24 Aug 2013 18:25:01 +0200 Subject: [PATCH 091/133] Revert stupid whitespace --- CONTRIBUTING.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.markdown b/CONTRIBUTING.markdown index 88c0ced5..6df99625 100644 --- a/CONTRIBUTING.markdown +++ b/CONTRIBUTING.markdown @@ -68,7 +68,7 @@ You can find the documentation for jekyllrb.com in the Jekyll's repo on GitHub.com. All documentation pull requests should be directed at `master`. Pull -requests directed at another branch will not be accepted. +requests directed at another branch will not be accepted. The [Jekyll wiki](https://github.com/mojombo/jekyll/wiki) on GitHub can be freely updated without a pull request as all GitHub users have access. From 4abd93567f094a416fded96022673e1261a4e2b4 Mon Sep 17 00:00:00 2001 From: Anatol Broder Date: Fri, 30 Aug 2013 21:26:38 +0200 Subject: [PATCH 092/133] Example FTW --- features/site_data.feature | 8 ++++---- site/docs/deployment-methods.md | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/features/site_data.feature b/features/site_data.feature index 9ab94056..faa266b7 100644 --- a/features/site_data.feature +++ b/features/site_data.feature @@ -4,10 +4,10 @@ Feature: Site data In order to make the site slightly dynamic Scenario: Use page variable in a page - Given I have an "contact.html" page with title "Contact" that contains "{{ page.title }}: email@me.com" + Given I have an "contact.html" page with title "Contact" that contains "{{ page.title }}: email@example.com" When I run jekyll Then the _site directory should exist - And I should see "Contact: email@me.com" in "_site/contact.html" + And I should see "Contact: email@example.com" in "_site/contact.html" Scenario Outline: Use page.path variable in a page Given I have a directory @@ -95,10 +95,10 @@ Feature: Site data Scenario: Use configuration date in site payload Given I have an "index.html" page that contains "{{ site.url }}" - And I have a configuration file with "url" set to "http://mysite.com" + And I have a configuration file with "url" set to "http://example.com" When I run jekyll Then the _site directory should exist - And I should see "http://mysite.com" in "_site/index.html" + And I should see "http://example.com" in "_site/index.html" Scenario: Access Jekyll version via jekyll.version Given I have an "index.html" page that contains "{{ jekyll.version }}" diff --git a/site/docs/deployment-methods.md b/site/docs/deployment-methods.md index 41c5472e..63fd7021 100644 --- a/site/docs/deployment-methods.md +++ b/site/docs/deployment-methods.md @@ -37,7 +37,7 @@ this](http://web.archive.org/web/20091223025644/http://www.taknado.com/en/2009/0 To have a remote server handle the deploy for you every time you push changes using Git, you can create a user account which has all the public keys that are authorized to deploy in its `authorized_keys` file. With that in place, setting up the post-receive hook is done as follows: {% highlight bash %} -laptop$ ssh deployer@myserver.com +laptop$ ssh deployer@example.com server$ mkdir myrepo.git server$ cd myrepo.git server$ git --bare init @@ -63,7 +63,7 @@ Finally, run the following command on any users laptop that needs to be able to deploy using this hook: {% highlight bash %} -laptops$ git remote add deploy deployer@myserver.com:~/myrepo.git +laptops$ git remote add deploy deployer@example.com:~/myrepo.git {% endhighlight %} Deploying is now as easy as telling nginx or Apache to look at From 386ea77e28ac567cbaa69274090bd8c3bd82d86d Mon Sep 17 00:00:00 2001 From: thomasdao Date: Tue, 12 Nov 2013 13:29:38 +0800 Subject: [PATCH 093/133] For issue #1714: Add documentation for post_url when posts are in subdirectory --- site/docs/templates.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/site/docs/templates.md b/site/docs/templates.md index c84eb827..7cf2a865 100644 --- a/site/docs/templates.md +++ b/site/docs/templates.md @@ -290,6 +290,15 @@ will generate the correct permalink URL for the post you specify. {% endraw %} {% endhighlight %} +If you organize your posts in subdirectories, you need to include subdirectory +path to the post: + +{% highlight text %} +{% raw %} +{% post_url /subdir/2010-07-21-name-of-post %} +{% endraw %} +{% endhighlight %} + There is no need to include the file extension when using the `post_url` tag. You can also use this tag to create a link to a post in Markdown as follows: From 8382a8b91b2fc84d569fbdfc43ea9c099d409944 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Thu, 14 Nov 2013 20:47:42 +0100 Subject: [PATCH 094/133] add test case for variable include tag in a loop --- features/include_tag.feature | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/features/include_tag.feature b/features/include_tag.feature index 3abff4c7..587784dc 100644 --- a/features/include_tag.feature +++ b/features/include_tag.feature @@ -46,3 +46,12 @@ Feature: Include tags When I run jekyll Then the _site directory should exist And I should see "a snippet that works with parameters" in "_site/index.html" + + Scenario: Include a variable file in a loop + Given I have an _includes directory + And I have an "_includes/one.html" file that contains "one" + And I have an "_includes/two.html" file that contains "two" + And I have an "index.html" page with files "[one.html, two.html]" that contains "{% for file in page.files %}{% include {{file}} %} {% endfor %}" + When I run jekyll + Then the _site directory should exist + And I should see "one two" in "_site/index.html" From 5e0af8499324f985501f45bfa6f74954cf684206 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Thu, 14 Nov 2013 20:53:59 +0100 Subject: [PATCH 095/133] fix include tag: don't store variable value This fixes the bug reported in #1495 (comments). --- lib/jekyll/tags/include.rb | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/jekyll/tags/include.rb b/lib/jekyll/tags/include.rb index d26ea7b4..15f99507 100644 --- a/lib/jekyll/tags/include.rb +++ b/lib/jekyll/tags/include.rb @@ -43,8 +43,8 @@ module Jekyll params end - def validate_file_name - if @file !~ /^[a-zA-Z0-9_\/\.-]+$/ || @file =~ /\.\// || @file =~ /\/\./ + def validate_file_name(file) + if file !~ /^[a-zA-Z0-9_\/\.-]+$/ || file =~ /\.\// || file =~ /\/\./ raise ArgumentError.new <<-eos Invalid syntax for include tag. File contains invalid characters or sequences: @@ -82,7 +82,7 @@ eos def retrieve_variable(context) if /\{\{([\w\-\.]+)\}\}/ =~ @file raise ArgumentError.new("No variable #{$1} was found in include tag") if context[$1].nil? - @file = context[$1] + context[$1] end end @@ -90,13 +90,13 @@ eos dir = File.join(context.registers[:site].source, INCLUDES_DIR) validate_dir(dir, context.registers[:site].safe) - retrieve_variable(context) - validate_file_name + file = retrieve_variable(context) || @file + validate_file_name(file) - file = File.join(dir, @file) - validate_file(file, context.registers[:site].safe) + path = File.join(dir, file) + validate_file(path, context.registers[:site].safe) - partial = Liquid::Template.parse(source(file, context)) + partial = Liquid::Template.parse(source(path, context)) context.stack do context['include'] = parse_params(context) if @params From 1d81f2553d610f79450dbeeefdd3999051660ece Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Fri, 15 Nov 2013 08:26:45 -0600 Subject: [PATCH 096/133] Update history to reflect merge of #1726 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 3673ccd2..28b30616 100644 --- a/History.markdown +++ b/History.markdown @@ -6,6 +6,7 @@ * Add a `--prefix` option to passthrough for the importers (#1669) ### Bug Fixes + * Fix the include tag when ran in a loop (#1726) ### Development Fixes * Extract `Site#filter_entries` into its own object (#1697) From dfffc2e72a20c199e656f6bfa6ca977475ee6a01 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Sat, 16 Nov 2013 13:12:06 -0500 Subject: [PATCH 097/133] Use Pathname#to_s instead of Pathname#to_path Fixes #1723. --- lib/jekyll/commands/build.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/commands/build.rb b/lib/jekyll/commands/build.rb index a0dd44e5..bfc69aa3 100644 --- a/lib/jekyll/commands/build.rb +++ b/lib/jekyll/commands/build.rb @@ -37,7 +37,7 @@ module Jekyll destination = options['destination'] begin - dest = Pathname.new(destination).relative_path_from(Pathname.new(source)).to_path + dest = Pathname.new(destination).relative_path_from(Pathname.new(source)).to_s ignored = Regexp.new(Regexp.escape(dest)) rescue ArgumentError # Destination is outside the source, no need to ignore it. From 315cfcd727a555b5df85b98116ab9c6a939945d4 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Sun, 17 Nov 2013 23:01:28 -0600 Subject: [PATCH 098/133] Update history to reflect merge of #1730 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 28b30616..0d599acf 100644 --- a/History.markdown +++ b/History.markdown @@ -7,6 +7,7 @@ ### Bug Fixes * Fix the include tag when ran in a loop (#1726) + * Fix errors when using `--watch` on 1.8.7 (#1730) ### Development Fixes * Extract `Site#filter_entries` into its own object (#1697) From cbee41330e0998b48cd73341bbb8e4522ab5975b Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 18 Nov 2013 18:56:38 -0500 Subject: [PATCH 099/133] Remove all the docs for migrations and link to http://import.jekyllrb.com --- site/docs/migrations.md | 250 +--------------------------------------- 1 file changed, 2 insertions(+), 248 deletions(-) diff --git a/site/docs/migrations.md b/site/docs/migrations.md index 12290e29..27ecf71d 100644 --- a/site/docs/migrations.md +++ b/site/docs/migrations.md @@ -7,251 +7,5 @@ permalink: /docs/migrations/ --- If you’re switching to Jekyll from another blogging system, Jekyll’s importers -can help you with the move. Most methods listed on this page require read access -to the database from your old system to generate posts for Jekyll. Each method -generates `.markdown` posts in the `_posts` directory based on the entries in -the foreign system. - -## Preparing for migrations - -Because the importers have many of their own dependencies, they are made -available via a separate gem called -[`jekyll-import`](https://github.com/jekyll/jekyll-import). To use them, all -you need to do is install the gem, and they will become available as part of -Jekyll's standard command line interface. - -{% highlight bash %} -$ gem install jekyll-import --pre -{% endhighlight %} - -
-
Jekyll-import requires you to manually install some dependencies.
-

If you are importing your blog from Drupal 6,7, Joomla, - Mephisto, Movable Type, Textpattern, or Typo (with mysql db), you need to install - `mysql` and `sequel` gems. If you are importing from a WordPress database, you - need to install `mysql2` and `sequel` gems, and if you are importing from Enki - or Typo (with postgresql db) you need to install `pg` and `sequel` gems.

-
- -You should now be all set to run the importers below. If you ever get stuck, you -can see help for each importer: - -{% highlight bash %} -$ jekyll help import # => See list of importers -$ jekyll help import IMPORTER # => See importer specific help -{% endhighlight %} - -Where IMPORTER is the name of the specific importer. - -
-
Note: Always double-check migrated content
-

- - Importers may not distinguish between published or private posts, so - you should always check that the content Jekyll generates for you appears as - you intended. - -

-
- - - -## WordPress - -### WordPress export files - -If hpricot is not already installed, you will need to run `gem install hpricot`. -Next, export your blog using the WordPress export utility. Assuming that the -exported file is saved as `wordpress.xml`, here is the command you need to run: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/wordpressdotcom"; - JekyllImport::WordpressDotCom.process({ :source => "wordpress.xml" })' -{% endhighlight %} - -
-
ProTip™: WordPress.com Export Tool
-

If you are migrating from a WordPress.com account, you can - access the export tool at the following URL: - `https://YOUR-USER-NAME.wordpress.com/wp-admin/export.php`.

-
- -### Using WordPress MySQL server connection - -If you want to import using a direct connection to the WordPress MySQL server, -here's how: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/wordpress"; - JekyllImport::WordPress.process({:dbname => "database", :user => "user", :pass => "pass"})' -{% endhighlight %} - -If you are using Webfaction and have to set up an [SSH -tunnel](http://docs.webfaction.com/user-guide/databases.html?highlight=mysql#starting-an-ssh-tunnel-with-ssh), -be sure to make the hostname (`127.0.0.1`) explicit, otherwise MySQL may block -your access based on `localhost` and `127.0.0.1` not being equivalent in its -authentication system: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/wordpress"; - JekyllImport::WordPress.process({:host => "127.0.0.1", :dbname => "database", :user => "user", :pass => "pass"})' -{% endhighlight %} - -### Further WordPress migration alternatives - -While the above methods work, they do not import much of the metadata that is -usually stored in WordPress posts and pages. If you need to export things like -pages, tags, custom fields, image attachments and so on, the following resources -might be useful to you: - -- [Exitwp](https://github.com/thomasf/exitwp) is a configurable tool written in - Python for migrating one or more WordPress blogs into Jekyll (Markdown) format - while keeping as much metadata as possible. Exitwp also downloads attachments - and pages. -- [A great - article](http://vitobotta.com/how-to-migrate-from-wordpress-to-jekyll/) with a - step-by-step guide for migrating a WordPress blog to Jekyll while keeping most - of the structure and metadata. -- [wpXml2Jekyll](https://github.com/theaob/wpXml2Jekyll) is an executable - windows application for creating Markdown posts from your WordPress XML file. - -## Drupal - -If you’re migrating from [Drupal](http://drupal.org), there are two migrators -for you, depending upon your Drupal version: -- [Drupal 6](https://github.com/jekyll/jekyll-import/blob/v0.1.0.beta1/lib/jekyll/jekyll-import/drupal6.rb) -- [Drupal 7](https://github.com/jekyll/jekyll-import/blob/v0.1.0.beta1/lib/jekyll/jekyll-import/drupal7.rb) - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/drupal6"; - JekyllImport::Drupal6.process("dbname", "user", "pass")' -# ... or ... -$ ruby -rubygems -e 'require "jekyll/jekyll-import/drupal7"; - JekyllImport::Drupal7.process("dbname", "user", "pass")' -{% endhighlight %} - -If you are connecting to a different host or need to specify a table prefix for -your database, you may optionally add those two parameters to the end of either -Drupal migrator execution: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/drupal6"; - JekyllImport::Drupal6.process("dbname", "user", "pass", "host", "table_prefix")' -# ... or ... -$ ruby -rubygems -e 'require "jekyll/jekyll-import/drupal7"; - JekyllImport::Drupal7.process("dbname", "user", "pass", "host", "table_prefix")' -{% endhighlight %} - -## Movable Type - -To import posts from Movable Type: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/mt"; - JekyllImport::MT.process("database", "user", "pass")' -{% endhighlight %} - -## Typo - -To import posts from Typo: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/typo"; - JekyllImport::Typo.process("database", "user", "pass")' -{% endhighlight %} - -This code has only been tested with Typo version 4+. - -## TextPattern - -To import posts from TextPattern: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/textpattern"; - JekyllImport::TextPattern.process("database_name", "username", "password", "hostname")' -{% endhighlight %} - -You will need to run the above from the parent directory of your `_import` -folder. For example, if `_import` is located in `/path/source/_import`, you will -need to run this code from `/path/source`. The hostname defaults to `localhost`, -all other variables are required. You may need to adjust the code used to filter -entries. Left alone, it will attempt to pull all entries that are live or -sticky. - -## Mephisto - -To import posts from Mephisto: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/mephisto"; - JekyllImport::Mephisto.process("database", "user", "password")' -{% endhighlight %} - -If your data is in Postgres, you should do this instead: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/mephisto"; - JekyllImport::Mephisto.postgres({:database => "database", :username=>"username", :password =>"password"})' -{% endhighlight %} - -## Blogger (Blogspot) - -To import posts from Blogger, see [this post about migrating from Blogger to -Jekyll](http://blog.coolaj86.com/articles/migrate-from-blogger-to-jekyll.html). If -that doesn’t work for you, you might want to try some of the following -alternatives: - -- [@kennym](https://github.com/kennym) created a [little migration - script](https://gist.github.com/1115810), because the solutions in the - previous article didn't work out for him. -- [@ngauthier](https://github.com/ngauthier) created [another - importer](https://gist.github.com/1506614) that imports comments, and does so - via blogger’s archive instead of the RSS feed. -- [@juniorz](https://github.com/juniorz) created [yet another - importer](https://gist.github.com/1564581) that works for - [Octopress](http://octopress.org). It is like [@ngauthier’s - version](https://gist.github.com/1506614) but separates drafts from posts, as - well as importing tags and permalinks. - -## Posterous - -To import posts from your primary Posterous blog: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/posterous"; - JekyllImport::Posterous.process("my_email", "my_pass")' -{% endhighlight %} - -For any other Posterous blog on your account, you will need to specify the -`blog_id` for the blog: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/posterous"; - JekyllImport::Posterous.process("my_email", "my_pass", "blog_id")' -{% endhighlight %} - -There is also an [alternative Posterous -migrator](https://github.com/pepijndevos/jekyll/blob/patch-1/lib/jekyll/migrators/posterous.rb) -that maintains permalinks and attempts to import images too. - -## Tumblr - -To import posts from Tumblr: - -{% highlight bash %} -$ ruby -rubygems -e 'require "jekyll/jekyll-import/tumblr"; - JekyllImport::Tumblr.process(url, format, grab_images, add_highlights, rewrite_urls)' -# url - String: your blog's URL -# format - String: the output file extension. Use "md" to have your content -# converted from HTML to Markdown. Defaults to "html". -# grab_images - Boolean: whether to download images as well. Defaults to false. -# add_highlights - Boolean: whether to wrap code blocks (indented 4 spaces) in a Liquid - "highlight" tag. Defaults to false. -# rewrite_urls - Boolean: whether to write pages that redirect from the old Tumblr paths - to the new Jekyll paths. Defaults to false. -{% endhighlight %} - -## Other Systems - -If you have a system for which there is currently no migrator, consider writing -one and sending us [a pull request](https://github.com/jekyll/jekyll-import). +can help you with the move. To learn more about importing your site to Jekyll, +visit our [`jekyll-import` docs site](http://import.jekyllrb.com). From f4918a623b056382e29528f4208942928a4f8ed0 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 18 Nov 2013 18:59:10 -0500 Subject: [PATCH 100/133] Update history to reflect merge of #1732 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 0d599acf..fc2c3dd4 100644 --- a/History.markdown +++ b/History.markdown @@ -21,6 +21,7 @@ * Add `emoji-for-jekyll` to list of third-part plugins (#1708) * Fix previous section link on plugins page to point to pagination page (#1707) * Add `org-mode` converter plugin to third-party plugins (#1711) + * Point "Blog migrations" page to http://import.jekyllrb.com (#1732) ## 1.3.0 / 2013-11-04 From aec4286ca6cb0669007a405ad67721cf55e2f794 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Kar=C3=A9kinian?= Date: Tue, 19 Nov 2013 17:32:11 +0100 Subject: [PATCH 101/133] Enable Travis' bundle caching It should speed up the builds significantly. See http://about.travis-ci.org/docs/user/caching/#Bundler for more details. --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 4c50a297..b1aacd13 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,5 @@ language: ruby +cache: bundler before_install: - gem install bundler rvm: From 063ee6fb67b62e9346ee1a53f012cb418eb95259 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Tue, 19 Nov 2013 13:49:52 -0500 Subject: [PATCH 102/133] Update history to reflect merge of #1734 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index fc2c3dd4..1aaddb3b 100644 --- a/History.markdown +++ b/History.markdown @@ -11,6 +11,7 @@ ### Development Fixes * Extract `Site#filter_entries` into its own object (#1697) + * Enable Travis' bundle caching (#1734) ### Site Enhancements * Fix drafts docs to indicate that draft time is based on file modification From 49d5c3457cfd304e82b976a4e002b20b08349e7e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Kar=C3=A9kinian?= Date: Wed, 20 Nov 2013 00:30:04 +0100 Subject: [PATCH 103/133] Remove extra trailing whitespace --- features/support/env.rb | 2 +- test/test_redcloth.rb | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/features/support/env.rb b/features/support/env.rb index 5ccbab98..0d207b41 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -50,7 +50,7 @@ def seconds_agnostic_datetime(datetime = Time.now) pieces = datetime.to_s.split(" ") if pieces.size == 6 # Ruby 1.8.7 date = pieces[0..2].join(" ") - time = seconds_agnostic_time(pieces[3]) + time = seconds_agnostic_time(pieces[3]) zone = pieces[4..5].join(" ") else # Ruby 1.9.1 or greater date, time, zone = pieces diff --git a/test/test_redcloth.rb b/test/test_redcloth.rb index 94cc9f49..964591be 100644 --- a/test/test_redcloth.rb +++ b/test/test_redcloth.rb @@ -7,7 +7,7 @@ class TestRedCloth < Test::Unit::TestCase @textile = Converters::Textile.new end - should "preserve single line breaks in HTML output" do + should "preserve single line breaks in HTML output" do assert_equal "

line1
\nline2

", @textile.convert("p. line1\nline2").strip end end @@ -20,7 +20,7 @@ class TestRedCloth < Test::Unit::TestCase @textile = Converters::Textile.new config end - should "preserve single line breaks in HTML output" do + should "preserve single line breaks in HTML output" do assert_equal "

line1
\nline2

", @textile.convert("p. line1\nline2").strip end end @@ -35,7 +35,7 @@ class TestRedCloth < Test::Unit::TestCase @textile = Converters::Textile.new config end - should "preserve single line breaks in HTML output" do + should "preserve single line breaks in HTML output" do assert_equal "

line1
\nline2

", @textile.convert("p. line1\nline2").strip end end From 8944cdf544db94c988a439ee339d8ef02b61d2e6 Mon Sep 17 00:00:00 2001 From: andrewhavens Date: Wed, 20 Nov 2013 21:45:05 -0800 Subject: [PATCH 104/133] Update link to example Rakefile to point to specific commit. The link was pointing to the latest version of the file which had been changed and no longer provided the intended example. --- site/docs/deployment-methods.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/docs/deployment-methods.md b/site/docs/deployment-methods.md index 41c5472e..b8ee5ab6 100644 --- a/site/docs/deployment-methods.md +++ b/site/docs/deployment-methods.md @@ -76,7 +76,7 @@ laptops$ git push deploy master ### Rake Another way to deploy your Jekyll site is to use [Rake](https://github.com/jimweirich/rake), [HighLine](https://github.com/JEG2/highline), and -[Net::SSH](http://net-ssh.rubyforge.org/). A more complex example of deploying Jekyll with Rake that deals with multiple branches can be found in [Git Ready](https://github.com/gitready/gitready/blob/en/Rakefile). +[Net::SSH](http://net-ssh.rubyforge.org/). A more complex example of deploying Jekyll with Rake that deals with multiple branches can be found in [Git Ready](https://github.com/gitready/gitready/blob/cdfbc4ec5321ff8d18c3ce936e9c749dbbc4f190/Rakefile). ### rsync From ed7fb46b96c4ff9128364ef2ac67557a573e9d54 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Thu, 21 Nov 2013 15:57:03 -0500 Subject: [PATCH 105/133] Update history to reflect merge of #1741 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 1aaddb3b..c012e78b 100644 --- a/History.markdown +++ b/History.markdown @@ -14,6 +14,7 @@ * Enable Travis' bundle caching (#1734) ### Site Enhancements + * Update link to example Rakefile to point to specific commit (#1741) * Fix drafts docs to indicate that draft time is based on file modification time, not `Time.now` (#1695) * Add `jekyll-monthly-archive-plugin` and `jekyll-category-archive-plugin` to From 3888a240689b6c15a7b40f25c8aebd1d4ddfdf31 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Thu, 21 Nov 2013 22:03:39 +0100 Subject: [PATCH 106/133] output including file for include tag error --- lib/jekyll/convertible.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/convertible.rb b/lib/jekyll/convertible.rb index 01ed0743..723b0da7 100644 --- a/lib/jekyll/convertible.rb +++ b/lib/jekyll/convertible.rb @@ -87,7 +87,7 @@ module Jekyll def render_liquid(content, payload, info, path = nil) Liquid::Template.parse(content).render!(payload, info) rescue Tags::IncludeTagError => e - Jekyll.logger.error "Liquid Exception:", "#{e.message} in #{e.path}" + Jekyll.logger.error "Liquid Exception:", "#{e.message} in #{e.path}, included in #{path || self.path}" raise e rescue Exception => e Jekyll.logger.error "Liquid Exception:", "#{e.message} in #{path || self.path}" From c5533e9016b83c2370bed430edc547867ee5c7e6 Mon Sep 17 00:00:00 2001 From: "maul.esel" Date: Fri, 22 Nov 2013 06:58:52 +0100 Subject: [PATCH 107/133] restrict rescue-clause in IncludeTag#render As it previously enclosed the whole method, it also wrapped file validation errors, which is not meant to be. Fixes #1745. --- lib/jekyll/tags/include.rb | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/lib/jekyll/tags/include.rb b/lib/jekyll/tags/include.rb index 15f99507..ee1636c7 100644 --- a/lib/jekyll/tags/include.rb +++ b/lib/jekyll/tags/include.rb @@ -96,14 +96,16 @@ eos path = File.join(dir, file) validate_file(path, context.registers[:site].safe) - partial = Liquid::Template.parse(source(path, context)) + begin + partial = Liquid::Template.parse(source(path, context)) - context.stack do - context['include'] = parse_params(context) if @params - partial.render!(context) + context.stack do + context['include'] = parse_params(context) if @params + partial.render!(context) + end + rescue => e + raise IncludeTagError.new e.message, File.join(INCLUDES_DIR, @file) end - rescue => e - raise IncludeTagError.new e.message, File.join(INCLUDES_DIR, @file) end def validate_dir(dir, safe) From 8595ea812cfcb1f62373402d7dfa662d8fb5c29f Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Fri, 22 Nov 2013 20:32:27 -0600 Subject: [PATCH 108/133] Update history to reflect merge of #1718 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index c012e78b..e550f06e 100644 --- a/History.markdown +++ b/History.markdown @@ -24,6 +24,7 @@ * Fix previous section link on plugins page to point to pagination page (#1707) * Add `org-mode` converter plugin to third-party plugins (#1711) * Point "Blog migrations" page to http://import.jekyllrb.com (#1732) + * Add docs for `post_url` when posts are in subdirectories (#1718) ## 1.3.0 / 2013-11-04 From 16f4d025abf09dada33c4cfb8ba227cb79022ac7 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Fri, 22 Nov 2013 22:23:25 -0600 Subject: [PATCH 109/133] Update history to reflect merge of #1736 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index e550f06e..1ae5bb55 100644 --- a/History.markdown +++ b/History.markdown @@ -12,6 +12,7 @@ ### Development Fixes * Extract `Site#filter_entries` into its own object (#1697) * Enable Travis' bundle caching (#1734) + * Remove trailing whitespace in some files (#1736) ### Site Enhancements * Update link to example Rakefile to point to specific commit (#1741) From 33be5b0361ec8cdd2dc7cd954537a9fef772ac1a Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Fri, 22 Nov 2013 22:30:27 -0600 Subject: [PATCH 110/133] Update history to reflect merge of #1746 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index 1ae5bb55..14981b4c 100644 --- a/History.markdown +++ b/History.markdown @@ -8,6 +8,8 @@ ### Bug Fixes * Fix the include tag when ran in a loop (#1726) * Fix errors when using `--watch` on 1.8.7 (#1730) + * Specify where the include is called from if an included file is + missing (#1746) ### Development Fixes * Extract `Site#filter_entries` into its own object (#1697) From 7cda916faaa1f724c94bc1b75a8106e2d8d6d92e Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Fri, 22 Nov 2013 23:00:20 -0600 Subject: [PATCH 111/133] Update history to reflect merge of #1448 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 14981b4c..1b7b5893 100644 --- a/History.markdown +++ b/History.markdown @@ -28,6 +28,7 @@ * Add `org-mode` converter plugin to third-party plugins (#1711) * Point "Blog migrations" page to http://import.jekyllrb.com (#1732) * Add docs for `post_url` when posts are in subdirectories (#1718) + * Update the docs to point to `example.com` (#1448) ## 1.3.0 / 2013-11-04 From 9182b1b7ae75f3aeef3668cd7131ca53b16ca868 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Kar=C3=A9kinian?= Date: Wed, 20 Nov 2013 00:33:56 +0100 Subject: [PATCH 112/133] Fix duplicate test case name --- test/test_tags.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/test_tags.rb b/test/test_tags.rb index 135bdd10..07547900 100644 --- a/test/test_tags.rb +++ b/test/test_tags.rb @@ -226,7 +226,7 @@ CONTENT assert_no_match /markdown\-html\-error/, @result end - should "have the url to the \"nested\" post from 2008-11-21" do + should "have the url to the \"complex\" post from 2008-11-21" do assert_match %r{1\s/2008/11/21/complex/}, @result assert_match %r{2\s/2008/11/21/complex/}, @result end From ce8e271b5dde580dc5f5330e5fb97c6bd91122ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Kar=C3=A9kinian?= Date: Mon, 25 Nov 2013 13:31:53 +0100 Subject: [PATCH 113/133] Remove trailing whitespace --- Rakefile | 2 +- lib/jekyll/tags/include.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Rakefile b/Rakefile index b65b2dd2..d76ec053 100644 --- a/Rakefile +++ b/Rakefile @@ -218,7 +218,7 @@ namespace :site do abort "You seem to have misplaced your History.markdown file. I can haz?" end end - + namespace :releases do desc "Create new release post" task :new, :version do |t, args| diff --git a/lib/jekyll/tags/include.rb b/lib/jekyll/tags/include.rb index ee1636c7..a261e6f5 100644 --- a/lib/jekyll/tags/include.rb +++ b/lib/jekyll/tags/include.rb @@ -13,7 +13,7 @@ module Jekyll SYNTAX_EXAMPLE = "{% include file.ext param='value' param2='value' %}" - VALID_SYNTAX = /([\w-]+)\s*=\s*(?:"([^"\\]*(?:\\.[^"\\]*)*)"|'([^'\\]*(?:\\.[^'\\]*)*)'|([\w\.-]+))/ + VALID_SYNTAX = /([\w-]+)\s*=\s*(?:"([^"\\]*(?:\\.[^"\\]*)*)"|'([^'\\]*(?:\\.[^'\\]*)*)'|([\w\.-]+))/ INCLUDES_DIR = '_includes' From 47eac96fdc45dca29c5d7a97ebb3135554a50137 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Mon, 25 Nov 2013 20:56:48 -0600 Subject: [PATCH 114/133] Update history to reflect merge of #1754 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 1b7b5893..134a4d35 100644 --- a/History.markdown +++ b/History.markdown @@ -15,6 +15,7 @@ * Extract `Site#filter_entries` into its own object (#1697) * Enable Travis' bundle caching (#1734) * Remove trailing whitespace in some files (#1736) + * Fix a duplicate test name (#1754) ### Site Enhancements * Update link to example Rakefile to point to specific commit (#1741) From eceebb23a697d845f164fa87b2ebb05c88ba264d Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Tue, 26 Nov 2013 12:44:55 -0500 Subject: [PATCH 115/133] Pagination generator should have :lowest priority --- lib/jekyll/generators/pagination.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/jekyll/generators/pagination.rb b/lib/jekyll/generators/pagination.rb index 79688ba7..d7250865 100644 --- a/lib/jekyll/generators/pagination.rb +++ b/lib/jekyll/generators/pagination.rb @@ -4,6 +4,9 @@ module Jekyll # This generator is safe from arbitrary code execution. safe true + # This generator should be passive with regard to its execution + priority :lowest + # Generate paginated pages if necessary. # # site - The Site. From 4cc0bdf8ff0d9df9042e40f5d3dc6aa42318c6ac Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Tue, 26 Nov 2013 19:46:46 -0600 Subject: [PATCH 116/133] Update history to reflect merge of #1759 --- History.markdown | 2 ++ 1 file changed, 2 insertions(+) diff --git a/History.markdown b/History.markdown index 134a4d35..ab15b65e 100644 --- a/History.markdown +++ b/History.markdown @@ -4,6 +4,8 @@ ### Minor Enhancements * Add a `--prefix` option to passthrough for the importers (#1669) + * Push the paginator plugin lower in the plugin priority order so + other plugins run before it (#1759) ### Bug Fixes * Fix the include tag when ran in a loop (#1726) From 91a4c5611ea1fcf3192d809c43186cc5f41887ef Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Tue, 26 Nov 2013 20:27:27 -0600 Subject: [PATCH 117/133] Prep for the 1.3.1 release --- History.markdown | 10 ++++++ jekyll.gemspec | 6 ++-- lib/jekyll.rb | 2 +- .../2013-11-26-jekyll-1-3-1-released.markdown | 21 ++++++++++++ site/docs/history.md | 33 +++++++++++++++++++ 5 files changed, 69 insertions(+), 3 deletions(-) create mode 100644 site/_posts/2013-11-26-jekyll-1-3-1-released.markdown diff --git a/History.markdown b/History.markdown index ab15b65e..e9cbed89 100644 --- a/History.markdown +++ b/History.markdown @@ -2,6 +2,16 @@ ### Major Enhancements +### Minor Enhancements + +### Bug Fixes + +### Development Fixes + +### Site Enhancements + +## 1.3.1 / 2013-11/26 + ### Minor Enhancements * Add a `--prefix` option to passthrough for the importers (#1669) * Push the paginator plugin lower in the plugin priority order so diff --git a/jekyll.gemspec b/jekyll.gemspec index 62a866a6..7720df11 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -4,9 +4,9 @@ Gem::Specification.new do |s| s.rubygems_version = '1.3.5' s.name = 'jekyll' - s.version = '1.3.0' + s.version = '1.3.1' s.license = 'MIT' - s.date = '2013-11-04' + s.date = '2013-11-26' s.rubyforge_project = 'jekyll' s.summary = "A simple, blog aware, static site generator." @@ -95,6 +95,7 @@ Gem::Specification.new do |s| lib/jekyll/core_ext.rb lib/jekyll/deprecator.rb lib/jekyll/draft.rb + lib/jekyll/entry_filter.rb lib/jekyll/errors.rb lib/jekyll/excerpt.rb lib/jekyll/filters.rb @@ -273,6 +274,7 @@ Gem::Specification.new do |s| test/test_configuration.rb test/test_convertible.rb test/test_core_ext.rb + test/test_entry_filter.rb test/test_excerpt.rb test/test_filters.rb test/test_generated_site.rb diff --git a/lib/jekyll.rb b/lib/jekyll.rb index f9f787b7..633994e4 100644 --- a/lib/jekyll.rb +++ b/lib/jekyll.rb @@ -62,7 +62,7 @@ require_all 'jekyll/tags' SafeYAML::OPTIONS[:suppress_warnings] = true module Jekyll - VERSION = '1.3.0' + VERSION = '1.3.1' # Public: Generate a Jekyll configuration Hash by merging the default # options with anything in _config.yml, and adding the given options on top. diff --git a/site/_posts/2013-11-26-jekyll-1-3-1-released.markdown b/site/_posts/2013-11-26-jekyll-1-3-1-released.markdown new file mode 100644 index 00000000..4b4c37d5 --- /dev/null +++ b/site/_posts/2013-11-26-jekyll-1-3-1-released.markdown @@ -0,0 +1,21 @@ +--- +layout: news_item +title: 'Jekyll 1.3.1 Released' +date: 2013-11-26 19:52:20 -0600 +author: mattr- +version: 1.3.1 +categories: [release] +--- + +Just in time for the US holiday Thanksgiving, we're releasing version +1.3.1 of Jekyll to address some of the issues seen since the +release of 1.3.0. + +In addition to a couple of other smaller bug fixes, the biggest thing +we've fixed is an issue with the `--watch` option with Ruby 1.8.7. For a +full run-down, visit our [change log](/docs/history/)! + +Thanks to all the people who have contributed to this release! They are +(in alphabetical order): Abhi Yerra, Anatol Broder, Andreas Möller, Greg +Karékinian, Sam Rayner, Santeri Paavolainen, Shigeya Suzuki, Yihang Ho, +albertogg, andrewhavens, maul.esel, and thomasdao diff --git a/site/docs/history.md b/site/docs/history.md index 3e2d051c..2c681aec 100644 --- a/site/docs/history.md +++ b/site/docs/history.md @@ -5,6 +5,39 @@ permalink: /docs/history/ prev_section: contributing --- +## 1.3.1 / 2013-11/26 + +### Minor Enhancements +- Add a `--prefix` option to passthrough for the importers ([#1669]({{ site.repository }}/issues/1669)) +- Push the paginator plugin lower in the plugin priority order so + other plugins run before it ([#1759]({{ site.repository }}/issues/1759)) + +### Bug Fixes +- Fix the include tag when ran in a loop ([#1726]({{ site.repository }}/issues/1726)) +- Fix errors when using `--watch` on 1.8.7 ([#1730]({{ site.repository }}/issues/1730)) +- Specify where the include is called from if an included file is + missing ([#1746]({{ site.repository }}/issues/1746)) + +### Development Fixes +- Extract `Site#filter_entries` into its own object ([#1697]({{ site.repository }}/issues/1697)) +- Enable Travis' bundle caching ([#1734]({{ site.repository }}/issues/1734)) +- Remove trailing whitespace in some files ([#1736]({{ site.repository }}/issues/1736)) +- Fix a duplicate test name ([#1754]({{ site.repository }}/issues/1754)) + +### Site Enhancements +- Update link to example Rakefile to point to specific commit ([#1741]({{ site.repository }}/issues/1741)) +- Fix drafts docs to indicate that draft time is based on file modification + time, not `Time.now` ([#1695]({{ site.repository }}/issues/1695)) +- Add `jekyll-monthly-archive-plugin` and `jekyll-category-archive-plugin` to + list of third-party plugins ([#1693]({{ site.repository }}/issues/1693)) +- Add `jekyll-asset-path-plugin` to list of third-party plugins ([#1670]({{ site.repository }}/issues/1670)) +- Add `emoji-for-jekyll` to list of third-part plugins ([#1708]({{ site.repository }}/issues/1708)) +- Fix previous section link on plugins page to point to pagination page ([#1707]({{ site.repository }}/issues/1707)) +- Add `org-mode` converter plugin to third-party plugins ([#1711]({{ site.repository }}/issues/1711)) +- Point "Blog migrations" page to http://import.jekyllrb.com ([#1732]({{ site.repository }}/issues/1732)) +- Add docs for `post_url` when posts are in subdirectories ([#1718]({{ site.repository }}/issues/1718)) +- Update the docs to point to `example.com` ([#1448]({{ site.repository }}/issues/1448)) + ## 1.3.0 / 2013-11-04 ### Major Enhancements From 4f337df2d873acde1b5f5e07a3813b79adf70b1b Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Tue, 26 Nov 2013 20:45:57 -0600 Subject: [PATCH 119/133] Update the gemspec with the release post --- jekyll.gemspec | 1 + 1 file changed, 1 insertion(+) diff --git a/jekyll.gemspec b/jekyll.gemspec index 7720df11..ee48478c 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -157,6 +157,7 @@ Gem::Specification.new do |s| site/_posts/2013-09-14-jekyll-1-2-1-released.markdown site/_posts/2013-10-28-jekyll-1-3-0-rc1-released.markdown site/_posts/2013-11-04-jekyll-1-3-0-released.markdown + site/_posts/2013-11-26-jekyll-1-3-1-released.markdown site/css/gridism.css site/css/normalize.css site/css/pygments.css From 9fa0f2ab269dd432c1018781be69c47c28ccce9e Mon Sep 17 00:00:00 2001 From: Yi Zeng Date: Wed, 27 Nov 2013 20:19:25 +1300 Subject: [PATCH 120/133] fix wrong case for a word --- site/_posts/2013-11-04-jekyll-1-3-0-released.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown index 2cddd5e6..1e325117 100644 --- a/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown +++ b/site/_posts/2013-11-04-jekyll-1-3-0-released.markdown @@ -19,7 +19,7 @@ Here are a few things we think you'll want to know about this release: repetition in your templates and to set site specific options without changing `_config.yml`. -* You can now Run `jekyll serve --detach` to boot up a WEBrick server in the +* You can now run `jekyll serve --detach` to boot up a WEBrick server in the background. **Note:** you'll need to run `kill [server_pid]` to shut the server down. When ran, you'll get a process id that you can use in place of `[server_pid]` From 51706e8da7d2a927832ec3ee6de7c6a328c4fbc6 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Thu, 28 Nov 2013 22:11:56 -0500 Subject: [PATCH 121/133] Parse TOML or YAML in Jekyll::Configuration. --- jekyll.gemspec | 1 + lib/jekyll/configuration.rb | 15 +++++++++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/jekyll.gemspec b/jekyll.gemspec index ee48478c..c3dafc33 100644 --- a/jekyll.gemspec +++ b/jekyll.gemspec @@ -32,6 +32,7 @@ Gem::Specification.new do |s| s.add_runtime_dependency('safe_yaml', "~> 0.9.7") s.add_runtime_dependency('colorator', "~> 0.1") s.add_runtime_dependency('redcarpet', "~> 2.3.0") + s.add_runtime_dependency('toml', '~> 0.0.4') s.add_development_dependency('rake', "~> 10.1") s.add_development_dependency('rdoc', "~> 3.11") diff --git a/lib/jekyll/configuration.rb b/lib/jekyll/configuration.rb index 442fa5e6..ae75034b 100644 --- a/lib/jekyll/configuration.rb +++ b/lib/jekyll/configuration.rb @@ -99,6 +99,17 @@ module Jekyll override['source'] || self['source'] || DEFAULTS['source'] end + def safe_load_file(filename) + case File.extname(filename) + when '.toml' + TOML.load_file(filename) + when /\.y(a)?ml/ + YAML.safe_load_file(filename) + else + raise ArgumentError, "No parser for '#{filename}' is available."kk + end + end + # Public: Generate list of configuration files from the override # # override - the command-line options hash @@ -121,8 +132,8 @@ module Jekyll # # Returns this configuration, overridden by the values in the file def read_config_file(file) - next_config = YAML.safe_load_file(file) - raise ArgumentError.new("Configuration file: (INVALID) #{file}".yellow) if !next_config.is_a?(Hash) + next_config = safe_load_file(file) + raise ArgumentError.new("Configuration file: (INVALID) #{file}".yellow) unless next_config.is_a?(Hash) Jekyll.logger.info "Configuration file:", file next_config rescue SystemCallError From 1e32af47a6fef6237744e8d9585853be9b765a33 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 29 Nov 2013 23:22:10 -0500 Subject: [PATCH 122/133] Better config file parser error if it's not there. --- lib/jekyll/configuration.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/configuration.rb b/lib/jekyll/configuration.rb index ae75034b..a58efd8c 100644 --- a/lib/jekyll/configuration.rb +++ b/lib/jekyll/configuration.rb @@ -106,7 +106,7 @@ module Jekyll when /\.y(a)?ml/ YAML.safe_load_file(filename) else - raise ArgumentError, "No parser for '#{filename}' is available."kk + raise ArgumentError, "No parser for '#{filename}' is available. Use a .toml or .y(a)ml file instead." end end From 22b95aee38567add4af283060cc4f310164d28dd Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 29 Nov 2013 23:33:25 -0500 Subject: [PATCH 123/133] Give that LoadError a good message. --- lib/jekyll/configuration.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/configuration.rb b/lib/jekyll/configuration.rb index a58efd8c..a72e51d8 100644 --- a/lib/jekyll/configuration.rb +++ b/lib/jekyll/configuration.rb @@ -142,7 +142,7 @@ module Jekyll {} else Jekyll.logger.error "Fatal:", "The configuration file '#{file}' could not be found." - raise LoadError + raise LoadError, "The Configuration file '#{file}' could not be found." end end From b8bbc6e08b7c3bee42d85ae3c970907ce8a53051 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 29 Nov 2013 23:33:38 -0500 Subject: [PATCH 124/133] require the TOML gem, idiot. --- lib/jekyll.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/jekyll.rb b/lib/jekyll.rb index 633994e4..2ec3c8ec 100644 --- a/lib/jekyll.rb +++ b/lib/jekyll.rb @@ -26,6 +26,7 @@ require 'pathname' require 'liquid' require 'maruku' require 'colorator' +require 'toml' # internal requires require 'jekyll/core_ext' From 3b0c8ad6541aef774399902e05b4b16cb073aa06 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Fri, 29 Nov 2013 23:33:52 -0500 Subject: [PATCH 125/133] Add some unit tests for TOML integration. --- test/source/_config.dev.toml | 2 ++ test/test_configuration.rb | 15 ++++++++++++--- 2 files changed, 14 insertions(+), 3 deletions(-) create mode 100644 test/source/_config.dev.toml diff --git a/test/source/_config.dev.toml b/test/source/_config.dev.toml new file mode 100644 index 00000000..7ac863f8 --- /dev/null +++ b/test/source/_config.dev.toml @@ -0,0 +1,2 @@ +baseurl = "/you-beautiful-blog-you" +title = "My magnificent site, wut" diff --git a/test/test_configuration.rb b/test/test_configuration.rb index c57408e5..d911b779 100644 --- a/test/test_configuration.rb +++ b/test/test_configuration.rb @@ -30,7 +30,7 @@ class TestConfiguration < Test::Unit::TestCase @config = Configuration[{"source" => source_dir}] @no_override = {} @one_config_file = {"config" => "config.yml"} - @multiple_files = {"config" => %w[config/site.yml config/deploy.yml configuration.yml]} + @multiple_files = {"config" => %w[config/site.yml config/deploy.toml configuration.yml]} end should "always return an array" do @@ -45,7 +45,7 @@ class TestConfiguration < Test::Unit::TestCase assert_equal %w[config.yml], @config.config_files(@one_config_file) end should "return an array of the config files if given many config files" do - assert_equal %w[config/site.yml config/deploy.yml configuration.yml], @config.config_files(@multiple_files) + assert_equal %w[config/site.yml config/deploy.toml configuration.yml], @config.config_files(@multiple_files) end end context "#backwards_compatibilize" do @@ -131,6 +131,7 @@ class TestConfiguration < Test::Unit::TestCase @paths = { :default => File.join(Dir.pwd, '_config.yml'), :other => File.join(Dir.pwd, '_config.live.yml'), + :toml => source_dir('_config.dev.toml'), :empty => "" } end @@ -153,12 +154,20 @@ class TestConfiguration < Test::Unit::TestCase assert_equal Jekyll::Configuration::DEFAULTS, Jekyll.configuration({ "config" => @paths[:empty] }) end + should "successfully load a TOML file" do + Jekyll.logger.log_level = Jekyll::Stevenson::WARN + assert_equal Jekyll::Configuration::DEFAULTS.merge({ "baseurl" => "/you-beautiful-blog-you", "title" => "My magnificent site, wut" }), Jekyll.configuration({ "config" => [@paths[:toml]] }) + Jekyll.logger.log_level = Jekyll::Stevenson::INFO + end + should "load multiple config files" do mock(YAML).safe_load_file(@paths[:default]) { Hash.new } mock(YAML).safe_load_file(@paths[:other]) { Hash.new } + mock(TOML).load_file(@paths[:toml]) { Hash.new } mock($stdout).puts("Configuration file: #{@paths[:default]}") mock($stdout).puts("Configuration file: #{@paths[:other]}") - assert_equal Jekyll::Configuration::DEFAULTS, Jekyll.configuration({ "config" => [@paths[:default], @paths[:other]] }) + mock($stdout).puts("Configuration file: #{@paths[:toml]}") + assert_equal Jekyll::Configuration::DEFAULTS, Jekyll.configuration({ "config" => [@paths[:default], @paths[:other], @paths[:toml]] }) end should "load multiple config files and last config should win" do From 63122fdafc0b7d8f46f846b2caae4abea65bdd35 Mon Sep 17 00:00:00 2001 From: David Sawyer Date: Sun, 1 Dec 2013 19:11:16 -0500 Subject: [PATCH 126/133] add a space between "find" and "an" --- lib/jekyll/generators/pagination.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jekyll/generators/pagination.rb b/lib/jekyll/generators/pagination.rb index d7250865..72dc5292 100644 --- a/lib/jekyll/generators/pagination.rb +++ b/lib/jekyll/generators/pagination.rb @@ -17,7 +17,7 @@ module Jekyll if template = template_page(site) paginate(site, template) else - Jekyll.logger.warn "Pagination:", "Pagination is enabled, but I couldn't find" + + Jekyll.logger.warn "Pagination:", "Pagination is enabled, but I couldn't find " + "an index.html page to use as the pagination template. Skipping pagination." end end From 9cfe1f0a9c49141bc86ba9a94e7fb15115513d31 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Sun, 1 Dec 2013 19:27:03 -0500 Subject: [PATCH 127/133] Update history to reflect merge of #1769 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index e9cbed89..0196ddee 100644 --- a/History.markdown +++ b/History.markdown @@ -5,6 +5,7 @@ ### Minor Enhancements ### Bug Fixes + * Add a space between two words in a Pagination warning message (#1769) ### Development Fixes From 6768977c27143637372998e144f92c55247ca6b0 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 2 Dec 2013 15:35:43 -0500 Subject: [PATCH 128/133] Update history to reflect merge of #1755 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 0196ddee..1eae43c7 100644 --- a/History.markdown +++ b/History.markdown @@ -8,6 +8,7 @@ * Add a space between two words in a Pagination warning message (#1769) ### Development Fixes + * Remove some whitespace in the code (#1755) ### Site Enhancements From 7af757a3fc1ca2d82657136ee6109c6972c4a844 Mon Sep 17 00:00:00 2001 From: Parker Moore Date: Mon, 2 Dec 2013 15:36:55 -0500 Subject: [PATCH 129/133] Update history to reflect merge of #1762 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 1eae43c7..12039509 100644 --- a/History.markdown +++ b/History.markdown @@ -11,6 +11,7 @@ * Remove some whitespace in the code (#1755) ### Site Enhancements + * Fixed case of a word in the Jekyll v1.3.0 release post (#1762) ## 1.3.1 / 2013-11/26 From eab027d03a7aef413283de2079c18f47f5d92576 Mon Sep 17 00:00:00 2001 From: Anatol Broder Date: Wed, 4 Dec 2013 23:06:08 +0100 Subject: [PATCH 130/133] =?UTF-8?q?Fix=20favicon=E2=80=99s=20type?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- site/_includes/top.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/_includes/top.html b/site/_includes/top.html index 46ca8639..e17496ce 100644 --- a/site/_includes/top.html +++ b/site/_includes/top.html @@ -12,6 +12,6 @@ - + From 4076b1240050e21ee9e0f498487cedd1334766ff Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 4 Dec 2013 20:25:34 -0600 Subject: [PATCH 131/133] Update history to reflect merge of #1772 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 12039509..27da1d7f 100644 --- a/History.markdown +++ b/History.markdown @@ -12,6 +12,7 @@ ### Site Enhancements * Fixed case of a word in the Jekyll v1.3.0 release post (#1762) + * Fixed the mime type for the favicon (#1772) ## 1.3.1 / 2013-11/26 From dc7be869708a09c1ce37d4eb6b0326861886b33c Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 4 Dec 2013 20:28:53 -0600 Subject: [PATCH 132/133] Update history to reflect merge of #1765 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 27da1d7f..697f9433 100644 --- a/History.markdown +++ b/History.markdown @@ -1,6 +1,7 @@ ## HEAD ### Major Enhancements + * Add support for TOML config files (#1765) ### Minor Enhancements From 654fe6117b188a3a65c7fc15939b1feed28793e8 Mon Sep 17 00:00:00 2001 From: Matt Rogers Date: Wed, 4 Dec 2013 20:40:56 -0600 Subject: [PATCH 133/133] Update history to reflect merge of #1682 --- History.markdown | 1 + 1 file changed, 1 insertion(+) diff --git a/History.markdown b/History.markdown index 697f9433..24d1cd5d 100644 --- a/History.markdown +++ b/History.markdown @@ -4,6 +4,7 @@ * Add support for TOML config files (#1765) ### Minor Enhancements + * Sort plugins as a way to establish a load order (#1682) ### Bug Fixes * Add a space between two words in a Pagination warning message (#1769)