osp 0.2.0 → 0.3.0.pre.dev.1
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/Gemfile.lock +1 -1
- data/bin/osp +41 -17
- data/lib/osp/version.rb +1 -1
- data/osp.gemspec +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 29a7260e8467924c0cfb61511807d2562a1dc102
|
4
|
+
data.tar.gz: 8d47df4ac02c3a0be9c129a370c415c85e2e9b7a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 831f2ae320e236c5f01e74076b5a1aa76aa289aee68109cd501e2da58864cd51a3563692b9c775668dce9c9339c53bc5869fba377c83fab7ffe05bec7bae13a4
|
7
|
+
data.tar.gz: d855ad637941341b19425b6b9c5dd7d2f33e4df9e1c6438b97c544ccb95d6ab073b60921d68ab1510e0ef9dd42fb1bdbdb26c3d0084ee1d7948fcacd7c5f5bf0
|
data/Gemfile.lock
CHANGED
data/bin/osp
CHANGED
@@ -60,7 +60,7 @@ puts 'Password: *****'
|
|
60
60
|
puts
|
61
61
|
|
62
62
|
@osp_class = TheFox::OSP::OSP
|
63
|
-
|
63
|
+
@osp_class = TheFox::OSP::OSPDev
|
64
64
|
|
65
65
|
printf "Calculating base hash: #{@osp_class::HASHES_N} (#{@osp_class::HASHES_EXP}-bit) - please wait ..."
|
66
66
|
@osp = @osp_class.new(email, password)
|
@@ -209,11 +209,14 @@ while true
|
|
209
209
|
when 'i'
|
210
210
|
puts
|
211
211
|
if found_hosts.count > 0
|
212
|
-
index =
|
213
|
-
|
214
|
-
|
212
|
+
index = 1
|
213
|
+
if found_hosts.count > 1
|
214
|
+
index = @cli.ask('Show host, select by number: ', Integer){ |q|
|
215
|
+
q.character = true if found_hosts.count < 10
|
216
|
+
q.in = 1..(found_hosts.count) }.to_i
|
217
|
+
puts
|
218
|
+
end
|
215
219
|
|
216
|
-
puts
|
217
220
|
puts "Host ##{index} selected:"
|
218
221
|
index -= 1
|
219
222
|
selected_host = nil
|
@@ -232,11 +235,14 @@ while true
|
|
232
235
|
when 'e'
|
233
236
|
puts
|
234
237
|
if found_hosts.count > 0
|
235
|
-
index =
|
236
|
-
|
237
|
-
|
238
|
+
index = 1
|
239
|
+
if found_hosts.count > 1
|
240
|
+
index = @cli.ask('Edit, select host by number: ', Integer){ |q|
|
241
|
+
q.character = true if found_hosts.count < 10
|
242
|
+
q.in = 1..(found_hosts.count) }.to_i
|
243
|
+
puts
|
244
|
+
end
|
238
245
|
|
239
|
-
puts
|
240
246
|
puts "Host ##{index} selected:"
|
241
247
|
index -= 1
|
242
248
|
selected_host = nil
|
@@ -255,14 +261,32 @@ while true
|
|
255
261
|
else
|
256
262
|
puts 'No hosts found.'
|
257
263
|
end
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
264
|
+
when 'd'
|
265
|
+
puts
|
266
|
+
if found_hosts.count > 0
|
267
|
+
index = 1
|
268
|
+
if found_hosts.count > 1
|
269
|
+
index = @cli.ask('Delete, select host by number: ', Integer){ |q|
|
270
|
+
q.character = true if found_hosts.count < 10
|
271
|
+
q.in = 1..(found_hosts.count) }.to_i
|
272
|
+
puts
|
273
|
+
end
|
274
|
+
|
275
|
+
puts "Delete host ##{index}."
|
276
|
+
index -= 1
|
277
|
+
selected_host = nil
|
278
|
+
begin
|
279
|
+
selected_host = found_hosts.values[index]
|
280
|
+
rescue Exception => e
|
281
|
+
puts "ERROR: #{e}"
|
282
|
+
end
|
283
|
+
|
284
|
+
if !selected_host.nil?
|
285
|
+
@database.remove_host(selected_host)
|
286
|
+
end
|
287
|
+
else
|
288
|
+
puts 'No hosts found.'
|
289
|
+
end
|
266
290
|
when 'q'
|
267
291
|
break
|
268
292
|
when '?'
|
data/lib/osp/version.rb
CHANGED
data/osp.gemspec
CHANGED
@@ -13,7 +13,7 @@ Gem::Specification.new do |spec|
|
|
13
13
|
spec.email = 'christian@fox21.at'
|
14
14
|
|
15
15
|
spec.summary = %q{One Shall Pass}
|
16
|
-
spec.description = %q{One Shall Pass for Command Line.}
|
16
|
+
spec.description = %q{Password Manager: One Shall Pass for Command Line.}
|
17
17
|
spec.homepage = TheFox::OSP::HOMEPAGE
|
18
18
|
spec.license = 'GPL-3.0'
|
19
19
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: osp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0.pre.dev.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Christian Mayer
|
@@ -80,7 +80,7 @@ dependencies:
|
|
80
80
|
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: '1.2'
|
83
|
-
description: One Shall Pass for Command Line.
|
83
|
+
description: 'Password Manager: One Shall Pass for Command Line.'
|
84
84
|
email: christian@fox21.at
|
85
85
|
executables:
|
86
86
|
- osp
|
@@ -123,9 +123,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
123
123
|
version: 2.1.0
|
124
124
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
125
125
|
requirements:
|
126
|
-
- - "
|
126
|
+
- - ">"
|
127
127
|
- !ruby/object:Gem::Version
|
128
|
-
version:
|
128
|
+
version: 1.3.1
|
129
129
|
requirements: []
|
130
130
|
rubyforge_project:
|
131
131
|
rubygems_version: 2.4.7
|