From 43721ddb36eb0ad87035d615042d6190b58d94bc Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Wed, 3 Feb 2016 14:24:28 -0500 Subject: [PATCH 1/6] Use Jekyll 3.0 for dev --- Gemfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Gemfile b/Gemfile index 1475b55..5f0bfcd 100644 --- a/Gemfile +++ b/Gemfile @@ -4,3 +4,4 @@ source 'https://rubygems.org' gemspec gem 'github-pages' +gem 'jekyll', "~> 3.0" From f5d57c1ddc056ebe03420a5a44015a1bd2eee353 Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Wed, 3 Feb 2016 14:26:08 -0500 Subject: [PATCH 2/6] Update Gemfile --- Gemfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile b/Gemfile index 5f0bfcd..3f4ecbd 100644 --- a/Gemfile +++ b/Gemfile @@ -3,5 +3,5 @@ source 'https://rubygems.org' # Specify your gem's dependencies in jekyll_seo_tags.gemspec gemspec -gem 'github-pages' +gem 'github-pages', ">= 44" gem 'jekyll', "~> 3.0" From b55443e8bdedb59a655a8b29881cadc1f6140604 Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Tue, 9 Feb 2016 16:30:01 -0500 Subject: [PATCH 3/6] fix gemfile to use github-pages version --- Gemfile | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/Gemfile b/Gemfile index 3f4ecbd..f31065e 100644 --- a/Gemfile +++ b/Gemfile @@ -1,7 +1,16 @@ source 'https://rubygems.org' +require 'json' +require 'open-uri' -# Specify your gem's dependencies in jekyll_seo_tags.gemspec gemspec -gem 'github-pages', ">= 44" -gem 'jekyll', "~> 3.0" +group :test do + versions = JSON.parse(open('https://pages.github.com/versions.json').read) + versions.delete('ruby') + versions.delete('jekyll-seo-tag') + versions.delete('github-pages') + + versions.each do |dep, version| + gem dep, version + end +end From 79b177b24870d2c9d413bc837a238424d0f69ca1 Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Tue, 9 Feb 2016 18:20:34 -0500 Subject: [PATCH 4/6] add content to fixtures --- spec/fixtures/_posts/2015-01-01-post.md | 2 ++ spec/fixtures/_posts/2015-01-02-other-post.md | 2 ++ 2 files changed, 4 insertions(+) diff --git a/spec/fixtures/_posts/2015-01-01-post.md b/spec/fixtures/_posts/2015-01-01-post.md index bd3048e..a91a54d 100644 --- a/spec/fixtures/_posts/2015-01-01-post.md +++ b/spec/fixtures/_posts/2015-01-01-post.md @@ -3,3 +3,5 @@ title: Some "post" & a test description: A post layout: default --- + +Blah blah diff --git a/spec/fixtures/_posts/2015-01-02-other-post.md b/spec/fixtures/_posts/2015-01-02-other-post.md index 0d6905d..bb25167 100644 --- a/spec/fixtures/_posts/2015-01-02-other-post.md +++ b/spec/fixtures/_posts/2015-01-02-other-post.md @@ -1,3 +1,5 @@ --- layout: default --- + +Blah blah From c1163793c69d63a4c0e957acb53ba1c74b200c83 Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Tue, 9 Feb 2016 18:26:38 -0500 Subject: [PATCH 5/6] use pages deps in dev? --- Gemfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Gemfile b/Gemfile index f31065e..a215af7 100644 --- a/Gemfile +++ b/Gemfile @@ -4,7 +4,7 @@ require 'open-uri' gemspec -group :test do +group :development, :test do versions = JSON.parse(open('https://pages.github.com/versions.json').read) versions.delete('ruby') versions.delete('jekyll-seo-tag') From 28858810ed58bb95e505524297d39bb060a5036e Mon Sep 17 00:00:00 2001 From: Ben Balter Date: Tue, 9 Feb 2016 18:33:53 -0500 Subject: [PATCH 6/6] fix missing endif from merge --- lib/template.html | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/lib/template.html b/lib/template.html index 53dca26..9a77b4c 100644 --- a/lib/template.html +++ b/lib/template.html @@ -4,28 +4,32 @@ {% assign seo_url = site.url | append: site.baseurl %} {% endif %} {% assign seo_url = seo_url | default: site.github.url %} - {% assign seo_site_title = site.title | default: site.name %} {% if page.title %} {% assign seo_title = page.title %} {% assign seo_page_title = page.title %} + {% if seo_site_title %} {% assign seo_title = seo_title | append:" - " | append: seo_site_title %} {% endif %} {% elsif seo_site_title %} {% assign seo_title = seo_site_title %} {% assign seo_page_title = seo_site_title %} + {% if site.description %} {% assign seo_title = seo_title | append:" - " | append: site.description %} {% endif %} {% endif %} + {% if seo_title %} {% assign seo_title = seo_title | markdownify | strip_html | strip_newlines | escape_once %} {% endif %} + {% if seo_site_title %} {% assign seo_site_title = seo_site_title | markdownify | strip_html | strip_newlines | escape_once %} {% endif %} + {% if seo_page_title %} {% assign seo_page_title = seo_page_title | markdownify | strip_html | strip_newlines | escape_once %} {% endif %} @@ -39,6 +43,7 @@ {% assign seo_author_name = page.author.name | default: page.author %} {% assign seo_author_twitter = page.author.twitter | default: page.author %} {% endif %} + {% if seo_author_twitter %} {% assign seo_author_twitter = seo_author_twitter | replace:"@","" | prepend:"@" %} {% endif %} @@ -84,6 +89,7 @@ {% if page.next.url %} {% endif %} + {% if page.previous.url %} {% endif %} @@ -105,9 +111,11 @@ + {% if page.image %} {% endif %} + {% if seo_author_twitter %} {% endif %} @@ -116,6 +124,7 @@ {% if site.facebook %} +{% endif %} {% if site.google_site_verification %}