Skip to content
Browse files

+ generators

  • Loading branch information...
1 parent a32aa11 commit eb96ed861f988bab56d221004ca8241704b7fa9b Andrew Zinenko committed Sep 23, 2012
View
1 .gitignore
@@ -12,5 +12,6 @@ pkg
\#*
.\#*
*.swp
+/example
config.yml
View
5 lib/vk-ruby/generators/vk/install/USAGE
@@ -0,0 +1,5 @@
+Description:
+ rails generate vk:install
+
+ This will create:
+ config/initialize/vk-ruby.rb
View
10 lib/vk-ruby/generators/vk/install/install_generator.rb
@@ -0,0 +1,10 @@
+module Vk
+ class InstallGenerator < Rails::Generators::Base
+ source_root File.expand_path('../templates', __FILE__)
+
+ # Creates the initialize file.
+ def generate_initializer
+ copy_file 'initializer.rb', 'config/initializers/vk-ruby.rb'
+ end
+ end
+end
View
2 lib/vk-ruby/generators/vk/install/templates/initializer.rb
@@ -0,0 +1,2 @@
+module VK
+end

0 comments on commit eb96ed8

Please sign in to comment.
Something went wrong with that request. Please try again.