Sha256: d2a4ba9365497ba1288a8a93eb992afcfeaaddb51e0f8f6a9b746afa96405604
Contents?: true
Size: 653 Bytes
Versions: 3
Compression:
Stored size: 653 Bytes
Contents
module Webhookr module Generators class InitGenerator < Rails::Generators::NamedBase desc "This generator creates an initializer file 'config/initializers/NAME.rb'" def init initializer("#{file_name}.rb") do file_contents end end def file_contents <<-eos # Webhookr Initializer ## Turn on http basic authentication for all plugins # Webhookr.config.basic_auth.username = "admin" # Webhookr.config.basic_auth.password = "password" ## Plugin Initializers go here ## eos end def generate_security_token rand(10000000000000000).floor.to_s(36) end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
webhookr-0.2.0 | lib/generators/webhookr/init_generator.rb |
webhookr-0.1.0 | lib/generators/webhookr/init_generator.rb |
webhookr-0.0.2 | lib/generators/webhookr/init_generator.rb |