relation_to_struct 1.2.1 → 1.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3f6639fc279267133528f887315dc029f1089880
4
- data.tar.gz: 6865cc290bf029d43c9b9dc72c75a262164bdbc8
3
+ metadata.gz: 7e144536f0414aeccfb958f8ccf336ecec3bc3e8
4
+ data.tar.gz: d5c5785c24474b4629081346ef5f1c2eb1620ffd
5
5
  SHA512:
6
- metadata.gz: eb0f5c09deb989f4bfede6bfa8f1e1cee914188b72923e69a98a468746564a8a030587130691a38eb58b97434f0258ac452065120c295fd2ba0138e68c004ce3
7
- data.tar.gz: c16127b078adb408b6076c2b5bbf60b0f93a29520398e46e916b46ff43ed55eb29cb095ce20bccf62bd2b4c713da9c030a0349c128f7a64b72c5390140d1e7df
6
+ metadata.gz: 0eede8794be139c326deca580ec817adffe746454848af34ee701e7a540d97267e6de44d0b9245c8f7128335b574013a2bea1fdb6c12f750c497f51cc49f47dc
7
+ data.tar.gz: 9b7e3a0e055c2501d7d5c23eb11bc08727d71a008f382580c328d746e43037d2c7791094acee393381ec8da822971ee3ec7679d1877b0c9bd2b9efb4b86d3b90
data/Appraisals CHANGED
@@ -1,4 +1,4 @@
1
- %w(4.1 4.2 5.0).each do |version|
1
+ %w(4.1 4.2 5.0 5.1).each do |version|
2
2
  appraise "rails-#{version.gsub(/\./, "-")}" do
3
3
  gem "rails", "~> #{version}.0"
4
4
  end
data/README.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # RelationToStruct
2
2
 
3
+ [![Build Status](https://semaphoreci.com/api/v1/jcoleman/relation_to_struct/branches/master/badge.svg)](https://semaphoreci.com/jcoleman/relation_to_struct)
4
+
3
5
  When one needs to use ActiveRecord to fetch specific values (whether subset columns of a model or arbitrary calculated columns), it's desirable to avoid the overhead of model instances and any associated callbacks.
4
6
 
5
7
  ActiveRecord::Relation#pluck solves a similar problem but returns tuples; I wanted to be able to return Ruby structs to benefit from named instance methods.
@@ -4,4 +4,4 @@ source "https://rubygems.org"
4
4
 
5
5
  gem "rails", "~> 4.1.0"
6
6
 
7
- gemspec :path => "../"
7
+ gemspec path: "../"
@@ -4,4 +4,4 @@ source "https://rubygems.org"
4
4
 
5
5
  gem "rails", "~> 4.2.0"
6
6
 
7
- gemspec :path => "../"
7
+ gemspec path: "../"
@@ -4,4 +4,4 @@ source "https://rubygems.org"
4
4
 
5
5
  gem "rails", "~> 5.0.0"
6
6
 
7
- gemspec :path => "../"
7
+ gemspec path: "../"
@@ -0,0 +1,7 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "rails", "~> 5.1.0"
6
+
7
+ gemspec path: "../"
@@ -1,3 +1,3 @@
1
1
  module RelationToStruct
2
- VERSION = "1.2.1"
2
+ VERSION = "1.2.2"
3
3
  end
@@ -26,6 +26,6 @@ Gem::Specification.new do |spec|
26
26
  spec.add_development_dependency "pry-byebug"
27
27
  spec.add_development_dependency "pg"
28
28
 
29
- spec.add_dependency "activerecord", ">= 4.1", "< 5.1"
30
- spec.add_dependency "activesupport", ">= 4.1", "< 5.1"
29
+ spec.add_dependency "activerecord", ">= 4.1", "< 5.2"
30
+ spec.add_dependency "activesupport", ">= 4.1", "< 5.2"
31
31
  end
@@ -4,7 +4,8 @@ ActiveRecord::Base.configurations = {
4
4
  "host" => 'localhost',
5
5
  "database" => 'relation_to_struct_tests',
6
6
  "encoding" => 'utf8',
7
- "username" => 'jcoleman',
7
+ "username" => ENV["DATABASE_POSTGRESQL_USERNAME"] || `whoami`.strip,
8
+ "password" => ENV["DATABASE_POSTGRESQL_PASSWORD"],
8
9
  },
9
10
  "sqlite" => {
10
11
  "adapter" => "sqlite3",
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: relation_to_struct
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Coleman
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-21 00:00:00.000000000 Z
11
+ date: 2018-06-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: appraisal
@@ -117,7 +117,7 @@ dependencies:
117
117
  version: '4.1'
118
118
  - - "<"
119
119
  - !ruby/object:Gem::Version
120
- version: '5.1'
120
+ version: '5.2'
121
121
  type: :runtime
122
122
  prerelease: false
123
123
  version_requirements: !ruby/object:Gem::Requirement
@@ -127,7 +127,7 @@ dependencies:
127
127
  version: '4.1'
128
128
  - - "<"
129
129
  - !ruby/object:Gem::Version
130
- version: '5.1'
130
+ version: '5.2'
131
131
  - !ruby/object:Gem::Dependency
132
132
  name: activesupport
133
133
  requirement: !ruby/object:Gem::Requirement
@@ -137,7 +137,7 @@ dependencies:
137
137
  version: '4.1'
138
138
  - - "<"
139
139
  - !ruby/object:Gem::Version
140
- version: '5.1'
140
+ version: '5.2'
141
141
  type: :runtime
142
142
  prerelease: false
143
143
  version_requirements: !ruby/object:Gem::Requirement
@@ -147,7 +147,7 @@ dependencies:
147
147
  version: '4.1'
148
148
  - - "<"
149
149
  - !ruby/object:Gem::Version
150
- version: '5.1'
150
+ version: '5.2'
151
151
  description: ''
152
152
  email:
153
153
  - jtc331@gmail.com
@@ -165,6 +165,7 @@ files:
165
165
  - gemfiles/rails_4_1.gemfile
166
166
  - gemfiles/rails_4_2.gemfile
167
167
  - gemfiles/rails_5_0.gemfile
168
+ - gemfiles/rails_5_1.gemfile
168
169
  - lib/relation_to_struct.rb
169
170
  - lib/relation_to_struct/active_record_base_extension.rb
170
171
  - lib/relation_to_struct/active_record_relation_extension.rb