-
Notifications
You must be signed in to change notification settings - Fork 11
/
Rakefile
40 lines (33 loc) · 885 Bytes
/
Rakefile
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
# frozen_string_literal: true
require 'rubygems'
require 'bundler'
begin
Bundler.setup(:default, :development)
rescue Bundler::BundlerError => e
warn e.message
warn 'Run `bundle install` to install missing gems'
exit e.status_code
end
require 'rake'
desc 'Code coverage detail'
task :simplecov do
ENV['COVERAGE'] = 'true'
Rake::Task['spec'].execute
end
require 'bundler/audit/cli'
task :bundler_audit do
%w[update check].each do |command|
Bundler::Audit::CLI.start [command]
end
end
require 'rubocop/rake_task'
RuboCop::RakeTask.new(:rubocop)
task default: %i[rubocop simplecov bundler_audit]
require 'rdoc/task'
Rake::RDocTask.new do |rdoc|
version = File.exist?('VERSION') ? File.read('VERSION') : ''
rdoc.rdoc_dir = 'rdoc'
rdoc.title = "signalwire-client #{version}"
rdoc.rdoc_files.include('README*')
rdoc.rdoc_files.include('lib/**/*.rb')
end