Sha256: e17ab2b373831191939f6cdb0f02f2cb3b975dd9d7ce31a5aa97b384930c8df7

Contents?: true

Size: 964 Bytes

Versions: 9

Compression:

Stored size: 964 Bytes

Contents

require 'bundler/gem_tasks'

require 'rubygems/tasks'
Gem::Tasks.new(release: false)

require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new

task :test do
  sh "rspec"
  sh "reek"
  sh "rubocop"
end

task default: :spec

desc "copy in PayrollHero's current style config files"
task :styleguide do
  require 'faraday'
  require 'pry'
  base = "https://raw.githubusercontent.com/payrollhero/styleguide/master/"
  files = %w{
    .rubocop.hound.yml
    .rubocop.yml
    .reek
    .codeclimate.yml
  }
  files.each do |file|
    puts "Fetching #{file} ..."
    url = "#{base}#{file}"
    rsp = Faraday.get(url)
    unless rsp.status == 200
      $stderr.puts "failing fetching: #{url}"
      $stderr.puts "  response: #{rsp.status}: #{rsp.body}"
      exit 1
    end
    File.open(file, "w") do |fh|
      fh.write(rsp.body)
    end
  end
end

desc "Updates the changelog"
task :changelog do
  sh "github_changelog_generator payrollhero/ph_model --simple-list"
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
ph_model-1.2.0 Rakefile
ph_model-1.1.3 Rakefile
ph_model-1.1.2 Rakefile
ph_model-1.1.1 Rakefile
ph_model-1.1.0 Rakefile
ph_model-1.0.2 Rakefile
ph_model-1.0.1 Rakefile
ph_model-1.0.0 Rakefile
ph_model-0.0.1 Rakefile