spectacles 0.0.2 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
data/Gemfile CHANGED
@@ -6,7 +6,3 @@ gemspec
6
6
  group :test do
7
7
  gem 'simplecov', :require => false
8
8
  end
9
-
10
- group :development do
11
- gem 'ruby-debug19', :require => "ruby-debug"
12
- end
@@ -13,7 +13,7 @@ module Spectacles
13
13
  AND table_type = 'VIEW'
14
14
  SQL
15
15
 
16
- query(q, name).map { |row| row[0] }
16
+ execute(q, name).map { |row| row['table_name'] }
17
17
  end
18
18
 
19
19
  def view_build_query(view, name = nil)
@@ -1,3 +1,3 @@
1
1
  module Spectacles
2
- VERSION = "0.0.2"
2
+ VERSION = "0.1.0"
3
3
  end
data/spectacles.gemspec CHANGED
@@ -1,31 +1,44 @@
1
1
  # -*- encoding: utf-8 -*-
2
- $:.push File.expand_path("../lib", __FILE__)
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
4
  require "spectacles/version"
4
5
 
5
- Gem::Specification.new do |s|
6
- s.name = "spectacles"
7
- s.version = Spectacles::VERSION
8
- s.authors = ["Adam Hutchison, Brandon Dewitt"]
9
- s.email = ["liveh2o@gmail.com, brandonsdewitt@gmail.com"]
10
- s.homepage = "http://github.com/liveh2o/spectacles"
11
- s.summary = %q{Spectacles (derived from RailsSQLViews) adds database view functionality to ActiveRecord.}
12
- s.description = %q{Still working out some of the kinks. Almost ready for Prime Time(TM). If you decide to use it and have problems, please report them at github.com/liveh2o/spectactles/issues}
6
+ Gem::Specification.new do |gem|
7
+ gem.version = Spectacles::VERSION
8
+ gem.name = "spectacles"
9
+ gem.authors = ["Adam Hutchison, Brandon Dewitt"]
10
+ gem.email = ["liveh2o@gmail.com, brandonsdewitt@gmail.com"]
11
+ gem.homepage = "http://github.com/liveh2o/spectacles"
12
+ gem.summary = %q{Spectacles (derived from RailsSQLViews) adds database view functionality to ActiveRecord.}
13
+ gem.description = %q{Still working out some of the kinks. Almost ready for Prime Time(TM). If you decide to use it and have problems, please report them at github.com/liveh2o/spectactles/issues}
13
14
 
14
- s.rubyforge_project = "spectacles"
15
+ gem.files = `git ls-files`.split($\)
16
+ gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
17
+ gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
18
+ gem.require_paths = ["lib"]
15
19
 
16
- s.files = `git ls-files`.split("\n")
17
- s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
18
- s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
19
- s.require_paths = ["lib"]
20
+ ##
21
+ # Dependencies
22
+ #
23
+ gem.add_dependency "activerecord"
24
+ gem.add_dependency "activesupport"
20
25
 
21
- # specify any dependencies here; for example:
22
- s.add_development_dependency "minitest"
23
- s.add_development_dependency "mysql"
24
- s.add_development_dependency "mysql2"
25
- s.add_development_dependency "pg"
26
- s.add_development_dependency "rake"
27
- s.add_development_dependency "sqlite3-ruby"
26
+ ##
27
+ # Development dependencies
28
+ #
29
+ gem.add_development_dependency "rake"
30
+ gem.add_development_dependency "minitest"
28
31
 
29
- s.add_runtime_dependency "activerecord"
30
- s.add_runtime_dependency "activesupport"
32
+ if defined?(JRUBY_VERSION)
33
+ gem.add_development_dependency "activerecord-jdbcmysql-adapter"
34
+ gem.add_development_dependency "activerecord-jdbcpostgresql-adapter"
35
+ gem.add_development_dependency "activerecord-jdbcsqlite3-adapter"
36
+
37
+ gem.platform = Gem::Platform.new('java')
38
+ else
39
+ gem.add_development_dependency "mysql"
40
+ gem.add_development_dependency "mysql2"
41
+ gem.add_development_dependency "pg"
42
+ gem.add_development_dependency "sqlite3-ruby"
43
+ end
31
44
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spectacles
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.1.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,33 +9,43 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-02-10 00:00:00.000000000Z
12
+ date: 2013-01-14 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
- name: minitest
16
- requirement: &2165825860 !ruby/object:Gem::Requirement
15
+ name: activerecord
16
+ requirement: !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
20
20
  - !ruby/object:Gem::Version
21
21
  version: '0'
22
- type: :development
22
+ type: :runtime
23
23
  prerelease: false
24
- version_requirements: *2165825860
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: '0'
25
30
  - !ruby/object:Gem::Dependency
26
- name: mysql
27
- requirement: &2165825440 !ruby/object:Gem::Requirement
31
+ name: activesupport
32
+ requirement: !ruby/object:Gem::Requirement
28
33
  none: false
29
34
  requirements:
30
35
  - - ! '>='
31
36
  - !ruby/object:Gem::Version
32
37
  version: '0'
33
- type: :development
38
+ type: :runtime
34
39
  prerelease: false
35
- version_requirements: *2165825440
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
36
46
  - !ruby/object:Gem::Dependency
37
- name: mysql2
38
- requirement: &2165825020 !ruby/object:Gem::Requirement
47
+ name: rake
48
+ requirement: !ruby/object:Gem::Requirement
39
49
  none: false
40
50
  requirements:
41
51
  - - ! '>='
@@ -43,10 +53,15 @@ dependencies:
43
53
  version: '0'
44
54
  type: :development
45
55
  prerelease: false
46
- version_requirements: *2165825020
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
47
62
  - !ruby/object:Gem::Dependency
48
- name: pg
49
- requirement: &2165824600 !ruby/object:Gem::Requirement
63
+ name: minitest
64
+ requirement: !ruby/object:Gem::Requirement
50
65
  none: false
51
66
  requirements:
52
67
  - - ! '>='
@@ -54,10 +69,15 @@ dependencies:
54
69
  version: '0'
55
70
  type: :development
56
71
  prerelease: false
57
- version_requirements: *2165824600
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - ! '>='
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
58
78
  - !ruby/object:Gem::Dependency
59
- name: rake
60
- requirement: &2165824180 !ruby/object:Gem::Requirement
79
+ name: mysql
80
+ requirement: !ruby/object:Gem::Requirement
61
81
  none: false
62
82
  requirements:
63
83
  - - ! '>='
@@ -65,10 +85,15 @@ dependencies:
65
85
  version: '0'
66
86
  type: :development
67
87
  prerelease: false
68
- version_requirements: *2165824180
88
+ version_requirements: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ! '>='
92
+ - !ruby/object:Gem::Version
93
+ version: '0'
69
94
  - !ruby/object:Gem::Dependency
70
- name: sqlite3-ruby
71
- requirement: &2165823760 !ruby/object:Gem::Requirement
95
+ name: mysql2
96
+ requirement: !ruby/object:Gem::Requirement
72
97
  none: false
73
98
  requirements:
74
99
  - - ! '>='
@@ -76,29 +101,44 @@ dependencies:
76
101
  version: '0'
77
102
  type: :development
78
103
  prerelease: false
79
- version_requirements: *2165823760
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ! '>='
108
+ - !ruby/object:Gem::Version
109
+ version: '0'
80
110
  - !ruby/object:Gem::Dependency
81
- name: activerecord
82
- requirement: &2165823340 !ruby/object:Gem::Requirement
111
+ name: pg
112
+ requirement: !ruby/object:Gem::Requirement
83
113
  none: false
84
114
  requirements:
85
115
  - - ! '>='
86
116
  - !ruby/object:Gem::Version
87
117
  version: '0'
88
- type: :runtime
118
+ type: :development
89
119
  prerelease: false
90
- version_requirements: *2165823340
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ none: false
122
+ requirements:
123
+ - - ! '>='
124
+ - !ruby/object:Gem::Version
125
+ version: '0'
91
126
  - !ruby/object:Gem::Dependency
92
- name: activesupport
93
- requirement: &2165822920 !ruby/object:Gem::Requirement
127
+ name: sqlite3-ruby
128
+ requirement: !ruby/object:Gem::Requirement
94
129
  none: false
95
130
  requirements:
96
131
  - - ! '>='
97
132
  - !ruby/object:Gem::Version
98
133
  version: '0'
99
- type: :runtime
134
+ type: :development
100
135
  prerelease: false
101
- version_requirements: *2165822920
136
+ version_requirements: !ruby/object:Gem::Requirement
137
+ none: false
138
+ requirements:
139
+ - - ! '>='
140
+ - !ruby/object:Gem::Version
141
+ version: '0'
102
142
  description: Still working out some of the kinks. Almost ready for Prime Time(TM).
103
143
  If you decide to use it and have problems, please report them at github.com/liveh2o/spectactles/issues
104
144
  email:
@@ -146,15 +186,21 @@ required_ruby_version: !ruby/object:Gem::Requirement
146
186
  - - ! '>='
147
187
  - !ruby/object:Gem::Version
148
188
  version: '0'
189
+ segments:
190
+ - 0
191
+ hash: 474239807801853941
149
192
  required_rubygems_version: !ruby/object:Gem::Requirement
150
193
  none: false
151
194
  requirements:
152
195
  - - ! '>='
153
196
  - !ruby/object:Gem::Version
154
197
  version: '0'
198
+ segments:
199
+ - 0
200
+ hash: 474239807801853941
155
201
  requirements: []
156
- rubyforge_project: spectacles
157
- rubygems_version: 1.8.15
202
+ rubyforge_project:
203
+ rubygems_version: 1.8.24
158
204
  signing_key:
159
205
  specification_version: 3
160
206
  summary: Spectacles (derived from RailsSQLViews) adds database view functionality