urban_pass 0.0.1.1 → 0.0.2

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: 36974a02287e0d6b8fca4c7bdb248843b6ccb5ed
4
- data.tar.gz: fb168261ee81b0b7cf2651795bae3ccc959acb9c
3
+ metadata.gz: 9a5a4eae9a5fe2253ec691b479947c8f57bf9e8a
4
+ data.tar.gz: 710c205824a6708c20d7d49359b37fb1861e7834
5
5
  SHA512:
6
- metadata.gz: f859d53175e71068ee9d4bbff9b3b5c9764f8a87960ac668f42e94eb71aaeff017d627595bf3c6637a6ffe80af385790721db05b59deb22aaae25c8fd5121a47
7
- data.tar.gz: ee71c2100f8cffe6e6398b2bc6c55914a9f0b57f1b150f18d7028c841e55b56fcabca1fd8282465b8cf573d8529acfbc6753686b3ac31c042a5f02229c8c4e30
6
+ metadata.gz: ad76d6ebf35ebc2545a511607f753a60c466a1523056c9babc18dfb1d7e4d6ef3dc8c0960e04d98be1677f26f18b8e3a32595d0bbb5de205698c1dbb179b22c2
7
+ data.tar.gz: 00e1b34b4336873f1251b98c7f0baafe9dbbf1c11abd860651cf6dbc95d685dff990f8eee92c0a7a4cd65be46a7964022ffdbfdc3d881288f35c829d5ca1b2d3
data/README.md CHANGED
@@ -7,17 +7,7 @@ After dealing with multiple password generators. We decided to create a password
7
7
 
8
8
  ## Installation
9
9
 
10
- Add this line to your application's Gemfile:
11
-
12
- ```ruby
13
- gem 'urban_pass'
14
- ```
15
-
16
- And then execute:
17
-
18
- $ bundle
19
-
20
- Or install it yourself as:
10
+ Install it yourself as:
21
11
 
22
12
  $ gem install urban_pass
23
13
 
data/bin/urban_pass CHANGED
@@ -1,4 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
2
  require 'urban_pass'
3
3
  pass_phrase = UrbanPass::Generate.new
4
- pass_phrase.generate
4
+ password = pass_phrase.generate_phrase
5
+ puts "Your password is: #{password}"
@@ -9,11 +9,11 @@ module UrbanPass
9
9
  urban = random_word
10
10
 
11
11
  # Remove the extra spaces
12
- phrase = remove_spaces(urban)
12
+ word = remove_spaces(urban)
13
13
 
14
14
  # Return the length of the phrase and print out the word
15
- puts "Your new password is: #{phrase}"
16
- puts "The word is #{phrase_length(phrase)} charcters long"
15
+ puts "Your word is: #{word}"
16
+ puts "The word is #{phrase_length(word)} charcters long"
17
17
  end
18
18
 
19
19
  def random_word
@@ -29,5 +29,15 @@ module UrbanPass
29
29
  def phrase_length(phrase)
30
30
  return phrase.length
31
31
  end
32
+
33
+ def generate_phrase
34
+ arr = []
35
+ 4.times do
36
+ word = random_word
37
+ arr << remove_spaces(word)
38
+ end
39
+ pass_phrase = arr.join
40
+ return pass_phrase
41
+ end
32
42
  end
33
43
  end
@@ -1,3 +1,3 @@
1
1
  module UrbanPass
2
- VERSION = "0.0.1.1"
2
+ VERSION = "0.0.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: urban_pass
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Erik Nilsen