File: Rakefile

package info (click to toggle)
puppet-lint 2.3.6-1
  • links: PTS, VCS
  • area: main
  • in suites: buster, sid
  • size: 928 kB
  • sloc: ruby: 9,051; sh: 395; makefile: 2
file content (42 lines) | stat: -rw-r--r-- 989 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
require 'rake'
require 'rspec/core/rake_task'
require 'puppet-lint'
require 'puppet-lint/tasks/release_test'

task :default => :test

RSpec::Core::RakeTask.new(:test)

begin
  require 'github_changelog_generator/task'
  GitHubChangelogGenerator::RakeTask.new(:changelog) do |config|
    version = PuppetLint::VERSION
    config.future_release = version.to_s
    config.exclude_labels = %w[duplicate question invalid wontfix release-pr documentation]
    config.enhancement_labels = %w[feature]
  end
rescue LoadError
  $stderr.puts 'Changelog generation requires Ruby 2.0 or higher'
end

begin
  require 'rubocop/rake_task'

  RuboCop::RakeTask.new(:rubocop) do |task|
    task.options = %w[-D -E]
    task.patterns = [
      'lib/**/*.rb',
      'spec/**/*.rb',
      'bin/*',
      '*.gemspec',
      'Gemfile',
      'Rakefile',
    ]
  end
rescue LoadError
  $stderr.puts 'Rubocop is not available for this version of Ruby.'
end

task :ci => [:test, :release_test]

# vim: syntax=ruby