tida_sina_weibo 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,24 @@
|
|
1
|
+
module TidaSinaWeibo
|
2
|
+
module Generators
|
3
|
+
class TidaSinaWeiboGenerator < Rails::Generators::NamedBase
|
4
|
+
include Rails::Generators::ResourceHelpers
|
5
|
+
|
6
|
+
namespace "tida_sina_weibo"
|
7
|
+
source_root File.expand_path("../templates", __FILE__)
|
8
|
+
|
9
|
+
desc "Generates a model with the given NAME (if one does not exist) with tida_sina_weibo " <<
|
10
|
+
"configuration plus a migration file and tida_sina_weibo routes."
|
11
|
+
|
12
|
+
hook_for :orm
|
13
|
+
|
14
|
+
# class_option :routes, :desc => "Generate routes", :type => :boolean, :default => true
|
15
|
+
|
16
|
+
# def add_devise_routes
|
17
|
+
# devise_route = "devise_for :#{plural_name}"
|
18
|
+
# devise_route << %Q(, :class_name => "#{class_name}") if class_name.include?("::")
|
19
|
+
# devise_route << %Q(, :skip => :all) unless options.routes?
|
20
|
+
# route devise_route
|
21
|
+
# end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tida_sina_weibo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -80,6 +80,7 @@ files:
|
|
80
80
|
- lib/generators/tida_sina_weibo/.DS_Store
|
81
81
|
- lib/generators/tida_sina_weibo/install_generator.rb
|
82
82
|
- lib/generators/tida_sina_weibo/orm_helpers.rb
|
83
|
+
- lib/generators/tida_sina_weibo/tida_sina_weibo_generator.rb
|
83
84
|
- lib/tida_sina_weibo.rb
|
84
85
|
- lib/tida_sina_weibo/api_wrapper.rb
|
85
86
|
- lib/tida_sina_weibo/exceptions.rb
|