ridgepole 0.7.6 → 0.7.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +3 -1
- data/lib/ridgepole/cli/config.rb +10 -3
- data/lib/ridgepole/version.rb +1 -1
- data/spec/mysql/cli/config_spec.rb +3 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ccc0e3aba24f15cbe231cda77afbb12ee6b76578a569add69dc59597a0bdfeda
|
|
4
|
+
data.tar.gz: a24d8667ffcef19f3b520479df779795781a6fbf6d49926abf4396af21f1cfd4
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 6f90360bac6042f0715dae4ba8292461d708c0155bfa200125dea16a945908247d99db8031f20ef88499924678b4e55762609522e0a62e44e7ddd26ee327be12
|
|
7
|
+
data.tar.gz: 4f29137ad9cc8a81f6ccb456d9137567080cb7a1dcc5ef1ffdad911a66bf82deb3c0c116408d317d93ba1e1ad4c235e3320d11cff420c348fe9635579bb074cd
|
data/README.md
CHANGED
|
@@ -97,6 +97,8 @@ It defines DB schema using [Rails DSL](http://guides.rubyonrails.org/migrations.
|
|
|
97
97
|
* `>= 0.7.6`
|
|
98
98
|
* Fix database url check ([pull#266](https://github.com/winebarrel/ridgepole/pull/266))
|
|
99
99
|
* Add ignore option ([pull#267](https://github.com/winebarrel/ridgepole/pull/267))
|
|
100
|
+
* `>= 0.7.7`
|
|
101
|
+
* Support URI query string ([pull#273](https://github.com/winebarrel/ridgepole/pull/273))
|
|
100
102
|
</details>
|
|
101
103
|
|
|
102
104
|
## Installation
|
|
@@ -117,7 +119,7 @@ Or install it yourself as:
|
|
|
117
119
|
|
|
118
120
|
see https://github.com/winebarrel/ridgepole/releases.
|
|
119
121
|
|
|
120
|
-
### Install from
|
|
122
|
+
### Install from deb
|
|
121
123
|
|
|
122
124
|
```sh
|
|
123
125
|
sudo dpkg -i ridgepole_x.x.x+xxx-x_amd64.deb
|
data/lib/ridgepole/cli/config.rb
CHANGED
|
@@ -60,14 +60,21 @@ module Ridgepole
|
|
|
60
60
|
end
|
|
61
61
|
end
|
|
62
62
|
|
|
63
|
-
|
|
63
|
+
query_hash =
|
|
64
|
+
if uri.query
|
|
65
|
+
uri.query.split('&').map { |pair| pair.split('=') }.to_h
|
|
66
|
+
else
|
|
67
|
+
{}
|
|
68
|
+
end
|
|
69
|
+
|
|
70
|
+
query_hash.merge(
|
|
64
71
|
'adapter' => uri.scheme,
|
|
65
72
|
'username' => CGI.unescape(uri.user),
|
|
66
73
|
'password' => uri.password ? CGI.unescape(uri.password) : nil,
|
|
67
74
|
'host' => uri.host,
|
|
68
75
|
'port' => uri.port,
|
|
69
|
-
'database' => CGI.unescape(uri.path.sub(%r{\A/}, ''))
|
|
70
|
-
|
|
76
|
+
'database' => CGI.unescape(uri.path.sub(%r{\A/}, ''))
|
|
77
|
+
)
|
|
71
78
|
end
|
|
72
79
|
end
|
|
73
80
|
end
|
data/lib/ridgepole/version.rb
CHANGED
|
@@ -109,7 +109,7 @@ describe Ridgepole::Config do
|
|
|
109
109
|
end
|
|
110
110
|
|
|
111
111
|
context 'when passed DATABASE_URL' do
|
|
112
|
-
let(:config) { 'mysql2://root:pass@127.0.0.1:3307/blog' }
|
|
112
|
+
let(:config) { 'mysql2://root:pass@127.0.0.1:3307/blog?pool=5&reaping_frequency=2' }
|
|
113
113
|
let(:env) { 'development' }
|
|
114
114
|
|
|
115
115
|
it {
|
|
@@ -118,6 +118,8 @@ describe Ridgepole::Config do
|
|
|
118
118
|
expect(subject['username']).to eq 'root'
|
|
119
119
|
expect(subject['password']).to eq 'pass'
|
|
120
120
|
expect(subject['port']).to eq 3307
|
|
121
|
+
expect(subject['pool']).to eq '5'
|
|
122
|
+
expect(subject['reaping_frequency']).to eq '2'
|
|
121
123
|
}
|
|
122
124
|
end
|
|
123
125
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ridgepole
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.7.
|
|
4
|
+
version: 0.7.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Genki Sugawara
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2019-
|
|
11
|
+
date: 2019-04-18 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activerecord
|