Sha256: 14a6412bc28daeb07934f581e68edc354f2af8e8bdca0607b471e149fa16f59a
Contents?: true
Size: 830 Bytes
Versions: 13
Compression:
Stored size: 830 Bytes
Contents
# frozen_string_literal: true module SwaggerDocsGenerator # # Generator Rails # # Create a initializer for rails application class InitializerGenerator < Rails::Generators::Base desc 'Generate a initializer for Swagger Docs Generator' INITIALIZER = <<-INIT # frozen_string_literal: true if Rails.env.doc? SwaggerDocsGenerator.configure do |config| config.swagger = '2.2.4' # Swagger version used config.base_path = '/' # Base to API config.host = 'localhost:3000' # Host api end SwaggerDocsGenerator.configure_info do |info| info.title = 'API example.com' # Title to API info.version = 'v1' # Version to API end end INIT # Create initializer def copy_initializer initializer 'swagger_docs_generator.rb', INITIALIZER end end end
Version data entries
13 entries across 13 versions & 1 rubygems