From 3a61d06dda7977c3d729c1eeb4a3241dab98d191 Mon Sep 17 00:00:00 2001 From: Pixelastic Date: Thu, 16 Jul 2015 14:48:46 +0200 Subject: [PATCH] test(travis): Limit compatibility to Ruby 2.0+ --- .travis.yml | 7 ++----- Gemfile | 4 +--- README.md | 5 +++++ Rakefile | 3 +++ scripts/test_full | 8 ++++++++ 5 files changed, 19 insertions(+), 8 deletions(-) create mode 100755 scripts/test_full diff --git a/.travis.yml b/.travis.yml index 1fa55f4..18c3792 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,4 @@ language: ruby rvm: - - '1.8.7' - - '1.9.2' - - '1.9.3' - - '2.2.1' - - rbx + - 2.1 + - 2.0 diff --git a/Gemfile b/Gemfile index 8b55d5d..dcbc2f4 100644 --- a/Gemfile +++ b/Gemfile @@ -1,7 +1,5 @@ source 'http://rubygems.org' -ruby '2.2.1' - gem 'algoliasearch', '~> 1.4' gem 'awesome_print', '~> 1.6' gem 'json', '~> 1.8' @@ -9,7 +7,7 @@ gem 'nokogiri', '~> 1.6' group :development do gem 'guard-rspec', '~> 4.6' - gem 'jekyll', '~> 2.5' + gem 'jekyll', '~> 2.5' # Jekyll custom commands only available from 2.5 gem 'jeweler', '~> 2.0' gem 'rspec', '~> 3.0' gem 'rubocop', '~> 0.31' diff --git a/README.md b/README.md index 7fb52c9..13000af 100644 --- a/README.md +++ b/README.md @@ -131,6 +131,11 @@ class AlgoliaSearchRecordExtractor end ``` +## Dependencies + +The `algoliasearch-jekyll` plugin works form versions of Jekyll starting from +2.5, with a version of Ruby of at least 2.0. + ## Searching This plugin will only index your data in your Algolia index. Adding search diff --git a/Rakefile b/Rakefile index 24e05dd..76233df 100644 --- a/Rakefile +++ b/Rakefile @@ -23,6 +23,9 @@ Jeweler::Tasks.new do |gem| '`jekyll algolia push`' gem.email = 'tim@pixelastic.com' gem.authors = ['Tim Carry'] + + gem.required_ruby_version = '2.0' + # dependencies defined in Gemfile end Jeweler::RubygemsDotOrgTasks.new diff --git a/scripts/test_full b/scripts/test_full new file mode 100755 index 0000000..1a24694 --- /dev/null +++ b/scripts/test_full @@ -0,0 +1,8 @@ +#!/usr/bin/env bash + +source ~/.rvm/scripts/rvm + +(rvm use 2.0 || rvm install ruby-2.0) && \ + rake && \ + (rvm use 2.1 || rvm install ruby-2.1) && \ + rake