From 1a854ad878bc43d192a7c28c0adf3d6b36d0c152 Mon Sep 17 00:00:00 2001 From: Simone Carletti Date: Thu, 8 Sep 2022 14:07:33 +0200 Subject: [PATCH] Cleanup Rakefile --- Rakefile | 21 ++++++++------------- whois-parser.gemspec | 18 +++++++++--------- 2 files changed, 17 insertions(+), 22 deletions(-) diff --git a/Rakefile b/Rakefile index ed1263e0..7344c477 100644 --- a/Rakefile +++ b/Rakefile @@ -1,31 +1,26 @@ -require 'bundler/gem_tasks' +# frozen_string_literal: true +require "bundler/gem_tasks" -# Run test by default. -task :default => :spec -task :test => :spec +task default: [:test] -require 'rspec/core/rake_task' +require "rspec/core/rake_task" RSpec::Core::RakeTask.new do |t| t.verbose = !ENV["VERBOSE"].nil? end +task test: :spec -require 'yard' + +require "yard/rake/yardoc_task" YARD::Rake::YardocTask.new(:yardoc) do |y| y.options = ["--output-dir", "yardoc"] end -namespace :yardoc do - task :clobber do - rm_r "yardoc" rescue nil - end -end - -task :clobber => "yardoc:clobber" +CLOBBER.include "yardoc" Dir["tasks/**/*.rake"].each do |file| diff --git a/whois-parser.gemspec b/whois-parser.gemspec index ff18da69..ce5914a8 100644 --- a/whois-parser.gemspec +++ b/whois-parser.gemspec @@ -1,16 +1,16 @@ # -*- encoding: utf-8 -*- -$:.push File.expand_path('../lib', __FILE__) -require 'whois/parser/version' +$:.push File.expand_path("../lib", __FILE__) +require "whois/parser/version" Gem::Specification.new do |s| - s.name = 'whois-parser' + s.name = "whois-parser" s.version = Whois::Parser::VERSION - s.authors = ['Simone Carletti'] - s.email = ['weppos@weppos.net'] - s.homepage = 'https://whoisrb.org/' - s.summary = 'A pure Ruby WHOIS parser.' - s.description = 'Whois Parser is a WHOIS parser written in pure Ruby. It can parse and convert responses into easy-to-use Ruby objects.' - s.license = 'MIT' + s.authors = ["Simone Carletti"] + s.email = ["weppos@weppos.net"] + s.homepage = "https://whoisrb.org/" + s.summary = "A pure Ruby WHOIS parser." + s.description = "Whois Parser is a WHOIS parser written in pure Ruby. It can parse and convert responses into easy-to-use Ruby objects." + s.license = "MIT" s.required_ruby_version = ">= 2.3"