-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
32 lines (22 loc) · 839 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
# frozen_string_literal: true
require 'grape-swagger/rake/oapi_tasks'
require 'rspec/core/rake_task'
require 'rubocop/rake_task'
require_relative 'lib/document_transfer'
require_relative 'lib/bootstrap/rake'
require_relative 'lib/config/application'
require_relative 'lib/api/api'
# Bootstrap the application for rake.
config = DocumentTransfer::Config::Application.from_environment
DocumentTransfer::Bootstrap::Rake.new(config).bootstrap
task default: %i[spec rubocop]
task :environment do # rubocop:disable Rake/Desc
require_relative 'lib/api/api'
end
GrapeSwagger::Rake::OapiTasks.new('::DocumentTransfer::API::API')
RuboCop::RakeTask.new(:rubocop) do |task|
task.requires << 'rubocop'
task.formatters = %w[pacman]
task.formatters << 'github' if ENV.fetch('GITHUB_ACTIONS', false)
end
RSpec::Core::RakeTask.new(:spec)