haikunator 1.1.0 → 1.1.1

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
- SHA1:
3
- metadata.gz: 2fef78768bf20722486d7686a36d34044747e04a
4
- data.tar.gz: ee83c6dd21f8f180a6d307d1e35153cad6b707aa
2
+ SHA256:
3
+ metadata.gz: be3fa8b9414e4135e6c760c9fdf59993b85a9b374716a4c5a9aa7eb3c95f1e4e
4
+ data.tar.gz: 95137758b3daf86d4806a59afa5f55978b7886e3e873ff3db4c75e65669e8e9f
5
5
  SHA512:
6
- metadata.gz: 0565bb6f7147e555b6287aafef4e70393cb2c28e97a74819e1c4a63496d0eeb9775470d31ca6fd9f9176e75f8edad5c384d1928e21a15afb9691be7aa1648ded
7
- data.tar.gz: 81f887bfcf2670e2f30940e986453afa1be7a00aa2cdc91687050ecab811da53d3417d8f9a04ecd4176622acc311e428f00c263e793f2348a0f667d792c2d49e
6
+ metadata.gz: 6767bb6aa931fe4b417090ccc00cf4bfac5664923852e42056f953ae35c3554b33c40ab087e950912e807905f737e569af72f42445dcf90364384eb9a0fe3790
7
+ data.tar.gz: a37d2cfc63e278d03bc7acd06fb19624d50938ec372eaed389a24e9bf8f5cc24004e1dec60f79433c4b1f4e4ef94ddeb047ecd66227cf924bf613574849a2126
data/.gitignore CHANGED
@@ -1,3 +1,4 @@
1
+ .tool-versions
1
2
  *.gem
2
3
  *.rbc
3
4
  .bundle
data/.travis.yml CHANGED
@@ -6,7 +6,6 @@ rvm:
6
6
  - 2.1.2
7
7
  - 2.1.0
8
8
  - 2.0.0
9
- - 1.9.3
10
9
 
11
10
  script: 'bundle exec rake'
12
11
 
data/README.md CHANGED
@@ -40,10 +40,6 @@ Haikunator.haikunate(9999, '.') # => "cool.leaf.6743"
40
40
  Haikunator.haikunate(0, ' ') # => "green fire"
41
41
  ```
42
42
 
43
- ## History
44
-
45
- View the [changelog](https://github.com/usmanbashir/haikunator/blob/master/CHANGELOG.md)
46
-
47
43
  ## Contributing
48
44
 
49
45
  Everyone is encouraged to help improve this project. Here are a few ways you can help:
@@ -53,7 +49,35 @@ Everyone is encouraged to help improve this project. Here are a few ways you can
53
49
  - Write, clarify, or fix documentation
54
50
  - Suggest or add new features
55
51
 
56
-
57
- ## License
58
-
59
- MIT
52
+ ## Language Ports
53
+
54
+ Haikunator has also been ported to other languages. Though, these projects are not
55
+ affiliated with or endorsed by me, but check them out:
56
+
57
+ - Go:
58
+ - [Go-Haikunator](https://github.com/yelinaung/go-haikunator)
59
+ - [Haikunator](https://github.com/gjohnson/haikunator)
60
+ - [Haikunator](https://github.com/taion809/haikunator)
61
+ - JavaScript:
62
+ - [HaikunatorJS](https://github.com/Atrox/haikunatorjs)
63
+ - Python:
64
+ - [PyHaikunator](https://github.com/ferhatelmas/pyhaikunator)
65
+ - [HaikunatorPy](https://github.com/Atrox/haikunatorpy)
66
+ - PHP:
67
+ - [HaikunatorPHP](https://github.com/Atrox/haikunatorphp)
68
+ - Elixir:
69
+ - [Haikunator](https://github.com/knrz/Haikunator)
70
+ - .NET:
71
+ - [Haikunator.NET](https://github.com/Atrox/haikunator.net)
72
+ - Java:
73
+ - [HaikunatorJAVA](https://github.com/Atrox/haikunatorjava)
74
+ - Dart:
75
+ - [HaikunatorDART](https://github.com/Atrox/haikunatordart)
76
+ - Rust
77
+ - [rust-haikunator](https://github.com/nishanths/rust-haikunator)
78
+ - Crystal
79
+ - [Haikunator](https://github.com/sanata-/haikunator)
80
+ - R
81
+ - [Haikunator](http://github.com/amrrs/haikunator)
82
+ - Clojure
83
+ - [clj-haikunator](https://github.com/staticweb-io/clj-haikunator)
data/lib/haikunator.rb CHANGED
@@ -4,17 +4,15 @@ require "securerandom"
4
4
  module Haikunator
5
5
  class << self
6
6
  def haikunate(token_range = 9999, delimiter = "-")
7
- seed = random_seed
8
-
9
- build(seed, token_range, delimiter)
7
+ build(token_range, delimiter)
10
8
  end
11
9
 
12
10
  private
13
11
 
14
- def build(seed, token_range, delimiter)
12
+ def build(token_range, delimiter)
15
13
  sections = [
16
- adjectives[seed % adjectives.length],
17
- nouns[seed % nouns.length],
14
+ adjectives[random_seed % adjectives.length],
15
+ nouns[random_seed % nouns.length],
18
16
  token(token_range)
19
17
  ]
20
18
 
@@ -22,7 +20,7 @@ module Haikunator
22
20
  end
23
21
 
24
22
  def random_seed
25
- (SecureRandom.random_number * (2**12)).floor
23
+ SecureRandom.random_number(4096)
26
24
  end
27
25
 
28
26
  def token(range)
@@ -36,7 +34,7 @@ module Haikunator
36
34
  twilight dawn crimson wispy weathered blue billowing
37
35
  broken cold damp falling frosty green long late lingering
38
36
  bold little morning muddy old red rough still small
39
- sparkling throbbing shy wandering withered wild black
37
+ sparkling thrumming shy wandering withered wild black
40
38
  young holy solitary fragrant aged snowy proud floral
41
39
  restless divine polished ancient purple lively nameless
42
40
  )
@@ -50,7 +48,7 @@ module Haikunator
50
48
  bush dew dust field fire flower firefly feather grass
51
49
  haze mountain night pond darkness snowflake silence
52
50
  sound sky shape surf thunder violet water wildflower
53
- wave water resonance sun wood dream cherry tree fog
51
+ wave water resonance sun log dream cherry tree fog
54
52
  frost voice paper frog smoke star
55
53
  )
56
54
  end
@@ -1,3 +1,3 @@
1
1
  module Haikunator
2
- VERSION = "1.1.0"
2
+ VERSION = "1.1.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: haikunator
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Usman Bashir
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-22 00:00:00.000000000 Z
11
+ date: 2021-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -64,7 +64,6 @@ files:
64
64
  - ".rspec"
65
65
  - ".rubocop.yml"
66
66
  - ".travis.yml"
67
- - CHANGELOG.md
68
67
  - Gemfile
69
68
  - LICENSE.txt
70
69
  - README.md
@@ -93,8 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
93
92
  - !ruby/object:Gem::Version
94
93
  version: '0'
95
94
  requirements: []
96
- rubyforge_project:
97
- rubygems_version: 2.2.2
95
+ rubygems_version: 3.0.3
98
96
  signing_key:
99
97
  specification_version: 4
100
98
  summary: Heroku-like random name generator.
data/CHANGELOG.md DELETED
@@ -1,3 +0,0 @@
1
- ## 1.0.0
2
-
3
- - First release