diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f92e714 --- /dev/null +++ b/.gitignore @@ -0,0 +1,18 @@ +/.bundle/ +/.yardoc +/Gemfile.lock +/_yardoc/ +/coverage/ +/doc/ +/pkg/ +/spec/reports/ +/tmp/ +*.bundle +*.so +*.o +*.a +mkmf.log +.vagrant/* +.DS_Store +.idea/* +*.gem diff --git a/.rubocop.yml b/.rubocop.yml new file mode 100644 index 0000000..8011955 --- /dev/null +++ b/.rubocop.yml @@ -0,0 +1,25 @@ + +MethodLength: + Max: 200 + +LineLength: + Max: 160 + +FileName: + Enabled: false + +PerceivedComplexity: + Enabled: false + +CyclomaticComplexity: + Enabled: false + +ClassLength: + Enabled: false + +IfUnlessModifier: + Enabled: false + +RegexpLiteral: + Enabled: false + diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..95ba777 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,18 @@ +language: ruby +cache: + - bundler +install: + - bundle install +rvm: + - 1.9.3 + - 2.0 + - 2.1 +notifications: + email: + recipients: + - mattjones@yieldbot.com + on_success: change + on_failure: always + +script: + - 'bundle exec rake default' diff --git a/README.md b/README.md index 46ef4ee..c60db49 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,20 @@ -## Sensu-Plugins-disk-checks +## Sensu-Plugins-elasticsearch -[![Build Status](https://travis-ci.org/sensu-plugins/sensu-plugins-elasticsearch.svg?branch=master)][1] -[![Gem Version](https://badge.fury.io/rb/sensu-plugins-elasticsearch.svg)][2] -[![Code Climate](https://codeclimate.com/github/sensu-plugins/sensu-plugins-elasticsearch/badges/gpa.svg)][3] -[![Test Coverage](https://codeclimate.com/github/sensu-plugins/sensu-plugins-elasticsearch/badges/coverage.svg)][4] -[![Dependency Status](https://gemnasium.com/sensu-plugins/sensu-plugins-elasticsearch.svg)][5] +[![Build Status](https://travis-ci.org/sensu-plugins/sensu-plugins-elasticsearch.svg?branch=master)](https://travis-ci.org/sensu-plugins/sensu-plugins-elasticsearch) +[![Gem Version](https://badge.fury.io/rb/sensu-plugins-elasticsearch.svg)](http://badge.fury.io/rb/sensu-plugins-elasticsearch) +[![Code Climate](https://codeclimate.com/github/sensu-plugins/sensu-plugins-elasticsearch/badges/gpa.svg)](https://codeclimate.com/github/sensu-plugins/sensu-plugins-elasticsearch) +[![Test Coverage](https://codeclimate.com/github/sensu-plugins/sensu-plugins-elasticsearch/badges/coverage.svg)](https://codeclimate.com/github/sensu-plugins/sensu-plugins-elasticsearch) +[![Dependency Status](https://gemnasium.com/sensu-plugins/sensu-plugins-elasticsearch.svg)](https://gemnasium.com/sensu-plugins/sensu-plugins-elasticsearch) ## Functionality ## Files - * - * - * - * + * /bin/check-es-cluster-status + * /bin/check-es-heap + * /bin/metrics-es-node-graphite + * /bin/check-es-file-descriptors + * /bin/metrics-es-cluster + * /bin/metrics-es-node ## Usage diff --git a/Rakefile b/Rakefile index 4e5d83a..c4ee4f2 100644 --- a/Rakefile +++ b/Rakefile @@ -1,19 +1,11 @@ - require 'bundler/gem_tasks' - require 'rspec/core/rake_task' - require 'yard' - require 'github/markup' - require 'rubocop/rake_task' - require 'redcarpet' - require 'yard/rake/yardoc_task' - desc 'Don\'t run Rubocop for unsupported versions' begin if RUBY_VERSION >= '2.0.0' diff --git a/bin/es-cluster-metrics.rb b/bin/metrics-es-cluster.rb similarity index 100% rename from bin/es-cluster-metrics.rb rename to bin/metrics-es-cluster.rb diff --git a/bin/es-node-graphite.rb b/bin/metrics-es-node-graphite.rb similarity index 100% rename from bin/es-node-graphite.rb rename to bin/metrics-es-node-graphite.rb diff --git a/bin/es-node-metrics.rb b/bin/metrics-es-node.rb similarity index 100% rename from bin/es-node-metrics.rb rename to bin/metrics-es-node.rb diff --git a/sensu-plugins-elasticsearch.gemspec b/sensu-plugins-elasticsearch.gemspec index b7bc6d1..f4125ed 100644 --- a/sensu-plugins-elasticsearch.gemspec +++ b/sensu-plugins-elasticsearch.gemspec @@ -31,23 +31,13 @@ Gem::Specification.new do |s| s.platform = ruby s.required_ruby_version = '>= 1.9.3' - - s.add_development_dependency 'codeclimate-test-reporter' 'XXX' - - s.add_development_dependency 'rubocop' '~> 0.17.0' - - s.add_development_dependency 'rspec' '~> 3.1' - - s.add_development_dependency 'bundler' '~> 1.7' - - s.add_development_dependency 'rake' '~> 10.0' - - s.add_development_dependency 'github-markup' 'XXX' - - s.add_development_dependency 'redcarpet' 'XXX' - - s.add_development_dependency 'yard' 'XXX' - - s.add_development_dependency 'pry' 'XXX' - + s.add_development_dependency 'codeclimate-test-reporter' + s.add_development_dependency 'rubocop', '~> 0.17.0' + s.add_development_dependency 'rspec', '~> 3.1' + s.add_development_dependency 'bundler', '~> 1.7' + s.add_development_dependency 'rake', '~> 10.0' + s.add_development_dependency 'github-markup' + s.add_development_dependency 'redcarpet' + s.add_development_dependency 'yard' + s.add_development_dependency 'pry' end