kbsecret 0.3.4 → 0.3.5

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9e427bad01fa405bb3dcb4f9b22989880e5f5146
4
- data.tar.gz: 68fe7b2649c0bf8db72980fc525d713c55e00428
3
+ metadata.gz: 8b802b8fb4a82e3770e3499246ae1a6762cab0b8
4
+ data.tar.gz: 0bf498fbdc1ba933f8b05c44d44bd6ba13305bbd
5
5
  SHA512:
6
- metadata.gz: 5fa72f2cf3aaf7209b5283f30e6a2be86978ffc72560e611a5b7bc90deca393cf73cf8f443613a19e015948e936e6e223b4d1795528fd2b7707de04bcc888ce0
7
- data.tar.gz: ff52763b60b00e78c92eaba9f71a76219544c3b6e08de8d64b03999f772c3e454c1f79e4df10f7a5fe2ade302e5c1bd7c2dac291bd01d7efb3359c9a9763cc94
6
+ metadata.gz: 4c507fc4cd4ab5652ea9f60a4307297c6754b07d4bac54bb7b80fc155850cdb9f0620151ac68386f58559208c7b7d51554e4eaca3d5f7f8fbdeb081ab11c97f2
7
+ data.tar.gz: f26e2393541371c80f2354d2f397221130b19c607075d974241872fb3381da85f29757f5f4eb3c5f43882a0fed3b35c1f70f691dcf6ae699d0271a1622ee1751
data/README.md CHANGED
@@ -71,6 +71,19 @@ $ kbsecret env -s dev-team --all
71
71
  export API_KEY='0xBADBEEF'
72
72
  ```
73
73
 
74
+ ### Manual Pages
75
+
76
+ kbsecret's manual pages can be found online
77
+ [here](https://yossarian.net/docs/kbsecret-man/kbsecret.1).
78
+
79
+ If you'd like to generate the roff versions for `man(1)`, you'll need `ronn(1)`:
80
+
81
+ ```bash
82
+ $ gem install ronn
83
+ $ make man
84
+ $ cp man/*.1 ${YOUR_MAN_DIR}
85
+ ```
86
+
74
87
  ### Shell Completion
75
88
 
76
89
  kbsecret provides shell completion functions for bash.
data/bin/kbsecret CHANGED
@@ -58,10 +58,12 @@ def help(*args)
58
58
  puts KBSECRET_HELP
59
59
  elsif builtin? command
60
60
  send "#{command}_help"
61
- else
61
+ elsif external? command
62
62
  # XXX: this probably doesn't make sense, since not every user command
63
63
  # will implement --help.
64
64
  exec expand(command), "--help"
65
+ else
66
+ KBSecret::CLI.die "Unknown command: '#{command}'."
65
67
  end
66
68
  end
67
69
 
@@ -142,5 +144,5 @@ if builtin? command
142
144
  elsif external? command
143
145
  exec expand(command), *ARGV
144
146
  else
145
- STDERR.puts "Fatal: Unknown command: '#{command}'."
147
+ KBSecret::CLI.die "Unknown command: '#{command}'."
146
148
  end
data/bin/kbsecret-list CHANGED
@@ -32,12 +32,13 @@ session = KBSecret::CLI.ensure_session opts[:session]
32
32
  records = session.records opts[:type]
33
33
 
34
34
  records.each do |record|
35
- line = "#{record.label}\n"
36
- line << <<~EOS if opts.show_all?
35
+ puts record.label
36
+
37
+ next unless opts.show_all?
38
+
39
+ puts <<~EOS
37
40
  \tType: #{record.type}
38
41
  \tLast changed: #{Time.at(record.timestamp)}
39
42
  \tRaw data: #{record.data}
40
43
  EOS
41
-
42
- puts line
43
44
  end
data/bin/kbsecret-login CHANGED
@@ -16,10 +16,10 @@ opts = Slop.parse suppress_errors: true do |o|
16
16
  kbsecret login gmail netflix
17
17
  EOS
18
18
 
19
+ o.string "-s", "--session", "the session name", default: :default
19
20
  o.bool "-a", "--all", "retrieve all login records, not just listed ones"
20
21
  o.bool "-x", "--terse", "output in label:username:password format"
21
22
  o.string "-i", "--ifs", "separate terse fields with this string", default: ":"
22
- o.string "-s", "--session", "the session name", default: :default
23
23
 
24
24
  o.on "-h", "--help" do
25
25
  puts o
data/lib/kbsecret.rb CHANGED
@@ -11,7 +11,7 @@ require_relative "kbsecret/cli"
11
11
  # The primary namespace for kbsecret.
12
12
  module KBSecret
13
13
  # kbsecret's current version
14
- VERSION = "0.3.4"
14
+ VERSION = "0.3.5"
15
15
 
16
16
  # fail very early if the user doesn't have keybase and KBFS running
17
17
  raise Keybase::KeybaseNotRunningError unless Keybase.running?
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kbsecret
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.4
4
+ version: 0.3.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - William Woodruff
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-06-04 00:00:00.000000000 Z
11
+ date: 2017-06-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: keybase-unofficial