sequel_tools 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/lib/sequel_tools/actions/connect_db.rb +1 -1
- data/lib/sequel_tools/actions/irb.rb +11 -3
- data/lib/sequel_tools/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 6c23442c4bad32fba906b23fffa3f92089a0f2e5df148839fdc4f52bd199515f
|
4
|
+
data.tar.gz: b7451d64a3e522b881c9e44f29d8d216011ab34691e76126467a2fdbc3bb9608
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b36fc069fe4119bc7c94e15c8d119c2d14a7fb9b2d019cc92f53b88537ac105b28c5ee0f545556bbcc459f7db0cc083b74d571cbb7cbce8c5cc720abec6bea2b
|
7
|
+
data.tar.gz: c91db0d9962cfc581ce28b52f5ed5bb6d3a72cd57d8e0eeb086b9b3c9b136792917ad26df4a3dc0c45e17ecedc2a72a512fd313bc488ca97ff7ce0c46b575103
|
@@ -8,7 +8,7 @@ SequelTools::ActionsManager::Action.register :connect_db, nil do |args, context|
|
|
8
8
|
next if context[:db]
|
9
9
|
config = context[:config]
|
10
10
|
context[:db] = db = SequelTools.suppress_java_output do
|
11
|
-
Sequel.connect context[:uri_builder].call
|
11
|
+
Sequel.connect context[:uri_builder].call(config), test: true
|
12
12
|
end
|
13
13
|
db.sql_log_level = config[:sql_log_level]
|
14
14
|
db.log_connection_info = false
|
@@ -5,8 +5,16 @@ require_relative '../actions_manager'
|
|
5
5
|
class SequelTools::ActionsManager
|
6
6
|
description = "Opens an IRB session started as 'sequel uri_to_database' (DB is available to irb)"
|
7
7
|
Action.register :irb, description do |args, context|
|
8
|
-
|
9
|
-
|
10
|
-
|
8
|
+
# This code does the job, but for some reason the test will timeout under JRuby
|
9
|
+
#config = context[:config]
|
10
|
+
#uri = context[:uri_builder][config]
|
11
|
+
#exec "bundle exec sequel #{uri}"
|
12
|
+
|
13
|
+
Action[:connect_db].run({}, context)
|
14
|
+
require 'irb'
|
15
|
+
::DB = context[:db]
|
16
|
+
ARGV.clear
|
17
|
+
puts 'Your database is stored in DB...'
|
18
|
+
IRB.start
|
11
19
|
end
|
12
20
|
end
|
data/lib/sequel_tools/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sequel_tools
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rodrigo Rosenfeld Rosas
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-01-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sequel
|
@@ -155,7 +155,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
155
155
|
version: '0'
|
156
156
|
requirements: []
|
157
157
|
rubyforge_project:
|
158
|
-
rubygems_version: 2.
|
158
|
+
rubygems_version: 2.7.3
|
159
159
|
signing_key:
|
160
160
|
specification_version: 4
|
161
161
|
summary: Add Rake tasks to manage Sequel migrations
|