pasqual 0.2.2 → 0.2.3

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: 7151ebbbdf4f82caf3e4334201df2da40b8efd39
4
- data.tar.gz: 43133d251cbe9bbe16f981885ca7943845e7b362
3
+ metadata.gz: 3dc65e48c4ab80f857b7701516769fc2cf5c9299
4
+ data.tar.gz: 55852e565eb39b0ad6a84d95e1f7a136e44bda94
5
5
  SHA512:
6
- metadata.gz: 64efac02abf75574f9ff36a4e8e8021d657cc413c7ee04324563001a37afe9f2beab8e138c76bb19101d540f5325a9412e11ededec860bc155bffaccce6f93ec
7
- data.tar.gz: 55a66489cfe5e45c66811dfd5e7f9a5f688e0c12082ac53fb27ef5edf4fc6afe56efa308249c92d5facb516518165c299f39a5480abf8132df3692c4703a4e9f
6
+ metadata.gz: 38908e869ba9ccf886fc0a634617ef08da6b55af409cadc6895a9e809461493e27426fdfa4e5a79945c839e26a9ac42dc46790c8bfdea2bc737162126af2ae64
7
+ data.tar.gz: 26477342192f903f43326276056a0f19935b245409eaffe5863cb4e8cbf71c54f4708f1faa02fc629a29ae2a81fcd14f6c7b1b2954ebdcd8234961a36465511b
data/CHANGELOG CHANGED
@@ -1,3 +1,9 @@
1
+ * 0.2.3 - 2017-11-17
2
+
3
+ * Enhancements
4
+
5
+ * Ignore psqlrc and pager when running `psql`
6
+
1
7
  * 0.2.2 - 2017-10-13
2
8
 
3
9
  * Enhancements
@@ -2,14 +2,16 @@ module Pasqual
2
2
 
3
3
  module Arglist
4
4
 
5
- def self.args(username, password, host, port, name)
5
+ def self.args(program, username, password, host, port, name)
6
6
  list = []
7
7
  list << '-h' << host if host.to_s.length > 0
8
8
  list << '-U' << username if username.to_s.length > 0
9
9
  list << '-p' << port.to_s if port.to_s.length > 0
10
10
  list << '-w' if password.to_s.length == 0
11
- list << '--no-psqlrc'
12
- list << '--pset' << 'pager=off'
11
+ if program == 'psql'
12
+ list << '--no-psqlrc'
13
+ list << '--pset' << 'pager=off'
14
+ end
13
15
 
14
16
  list + [name]
15
17
  end
data/lib/pasqual/cli.rb CHANGED
@@ -56,7 +56,7 @@ module Pasqual
56
56
  end
57
57
  db = pasqual(url)
58
58
  args = Pasqual::Arglist.
59
- args(db.username, db.password, db.host, db.port, db.name)
59
+ args('psql', db.username, db.password, db.host, db.port, db.name)
60
60
  if sql_args.any?
61
61
  args << '-c'
62
62
  args += sql_args.map(&:inspect)
@@ -26,7 +26,7 @@ module Pasqual
26
26
  outfile.sync = true
27
27
 
28
28
  process = ChildProcess.build program,
29
- *Arglist.args(username, password, host, port, name)
29
+ *Arglist.args(program, username, password, host, port, name)
30
30
 
31
31
  process.io.stdout = process.io.stderr = outfile
32
32
 
@@ -1,3 +1,3 @@
1
1
  module Pasqual
2
- VERSION = "0.2.2"
2
+ VERSION = "0.2.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pasqual
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Derek Kastner
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-10-16 00:00:00.000000000 Z
11
+ date: 2017-11-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: childprocess
@@ -130,7 +130,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
130
130
  version: '0'
131
131
  requirements: []
132
132
  rubyforge_project:
133
- rubygems_version: 2.5.1
133
+ rubygems_version: 2.6.11
134
134
  signing_key:
135
135
  specification_version: 4
136
136
  summary: Interface easily with postgres CLI tools