tagalog_haikunator 1.0.0
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 +7 -0
- data/.gitignore +23 -0
- data/.rspec +2 -0
- data/.rubocop.yml +14 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +22 -0
- data/README.md +3 -0
- data/Rakefile +8 -0
- data/lib/tagalog_haikunator/version.rb +3 -0
- data/lib/tagalog_haikunator.rb +48 -0
- data/tagalog_haikunator.gemspec +22 -0
- metadata +68 -0
checksums.yaml
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
---
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 05bed4d1d37da9662c562b42888dc7387428a4f07234a4d9484d623f64fe958f
|
|
4
|
+
data.tar.gz: 5dc0b3f7e106c33083336fefda33104823d011ffc70667fc6f70501bd5418c7f
|
|
5
|
+
SHA512:
|
|
6
|
+
metadata.gz: 1d5fa078328e12204b63b391e63cfa33215d84b444cae5096ecd28cdcaa37e6f2f3091ebe0b57e7977880e9bc94a537c85fdae5c1d9ce9a1b4c681dfaf6dc25c
|
|
7
|
+
data.tar.gz: 1277e8f4f1319d112fc91a8dd3262e0fcc95b29e612be7c3e78a9fbcb19181284ba53e9590bc3ce393a77769d93733f531f08ce26c215ae62231bfc317033d94
|
data/.gitignore
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
.tool-versions
|
|
2
|
+
*.gem
|
|
3
|
+
*.rbc
|
|
4
|
+
.bundle
|
|
5
|
+
.config
|
|
6
|
+
.yardoc
|
|
7
|
+
Gemfile.lock
|
|
8
|
+
InstalledFiles
|
|
9
|
+
_yardoc
|
|
10
|
+
coverage
|
|
11
|
+
doc/
|
|
12
|
+
lib/bundler/man
|
|
13
|
+
pkg
|
|
14
|
+
rdoc
|
|
15
|
+
spec/reports
|
|
16
|
+
test/tmp
|
|
17
|
+
test/version_tmp
|
|
18
|
+
tmp
|
|
19
|
+
*.bundle
|
|
20
|
+
*.so
|
|
21
|
+
*.o
|
|
22
|
+
*.a
|
|
23
|
+
mkmf.log
|
data/.rspec
ADDED
data/.rubocop.yml
ADDED
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
Copyright (c) 2015 Usman Bashir
|
|
2
|
+
|
|
3
|
+
MIT License
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
6
|
+
a copy of this software and associated documentation files (the
|
|
7
|
+
"Software"), to deal in the Software without restriction, including
|
|
8
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
|
9
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
|
10
|
+
permit persons to whom the Software is furnished to do so, subject to
|
|
11
|
+
the following conditions:
|
|
12
|
+
|
|
13
|
+
The above copyright notice and this permission notice shall be
|
|
14
|
+
included in all copies or substantial portions of the Software.
|
|
15
|
+
|
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
17
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
18
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
19
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
|
20
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
|
21
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
|
22
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.md
ADDED
data/Rakefile
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
require "tagalog_haikunator/version"
|
|
2
|
+
require "securerandom"
|
|
3
|
+
|
|
4
|
+
module TagalogHaikunator
|
|
5
|
+
class << self
|
|
6
|
+
def haikunate(token_range = 9999, delimiter = "-")
|
|
7
|
+
build(token_range, delimiter)
|
|
8
|
+
end
|
|
9
|
+
|
|
10
|
+
private
|
|
11
|
+
|
|
12
|
+
def build(token_range, delimiter)
|
|
13
|
+
sections = [
|
|
14
|
+
adjectives[random_seed % adjectives.length],
|
|
15
|
+
nouns[random_seed % nouns.length],
|
|
16
|
+
token(token_range)
|
|
17
|
+
]
|
|
18
|
+
|
|
19
|
+
sections.compact.join(delimiter)
|
|
20
|
+
end
|
|
21
|
+
|
|
22
|
+
def random_seed
|
|
23
|
+
SecureRandom.random_number(4096)
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
def token(range)
|
|
27
|
+
SecureRandom.random_number(range) if range > 0
|
|
28
|
+
end
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def adjectives
|
|
32
|
+
%w(magandang mapagkumbabang mapanlikhang masayang payapang mahiwagang mabangong makapangyarihang masidhing magulong maamong marangyang mapanlikhang makataong masiglang)
|
|
33
|
+
end
|
|
34
|
+
|
|
35
|
+
def nouns
|
|
36
|
+
%w(
|
|
37
|
+
waterfall river breeze moon rain wind sea morning
|
|
38
|
+
snow lake sunset pine shadow leaf dawn glitter forest
|
|
39
|
+
hill cloud meadow sun glade bird brook butterfly
|
|
40
|
+
bush dew dust field fire flower firefly feather grass
|
|
41
|
+
haze mountain night pond darkness snowflake silence
|
|
42
|
+
sound sky shape surf thunder violet water wildflower
|
|
43
|
+
wave water resonance sun log dream cherry tree fog
|
|
44
|
+
frost voice paper frog smoke star
|
|
45
|
+
)
|
|
46
|
+
end
|
|
47
|
+
end
|
|
48
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# coding: utf-8
|
|
2
|
+
lib = File.expand_path("../lib", __FILE__)
|
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
|
+
require "tagalog_haikunator/version"
|
|
5
|
+
|
|
6
|
+
Gem::Specification.new do |spec|
|
|
7
|
+
spec.name = "tagalog_haikunator"
|
|
8
|
+
spec.version = TagalogHaikunator::VERSION
|
|
9
|
+
spec.authors = ["Nicu Listana", "Usman Bashir"]
|
|
10
|
+
spec.email = ["nicu@adoboenterprises.com"]
|
|
11
|
+
spec.summary = "Heroku-like random name generator with Tagalog adjectives."
|
|
12
|
+
spec.description = "Generate memorable random names to use in your apps"\
|
|
13
|
+
" or anywhere else."
|
|
14
|
+
spec.homepage = "https://github.com/adobocorp/tagalog-haikunator"
|
|
15
|
+
spec.license = "MIT"
|
|
16
|
+
|
|
17
|
+
spec.files = `git ls-files -z`.split("\x0")
|
|
18
|
+
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
|
19
|
+
spec.require_paths = ["lib"]
|
|
20
|
+
|
|
21
|
+
spec.add_development_dependency "rake"
|
|
22
|
+
end
|
metadata
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
|
2
|
+
name: tagalog_haikunator
|
|
3
|
+
version: !ruby/object:Gem::Version
|
|
4
|
+
version: 1.0.0
|
|
5
|
+
platform: ruby
|
|
6
|
+
authors:
|
|
7
|
+
- Nicu Listana
|
|
8
|
+
- Usman Bashir
|
|
9
|
+
autorequire:
|
|
10
|
+
bindir: bin
|
|
11
|
+
cert_chain: []
|
|
12
|
+
date: 2025-06-06 00:00:00.000000000 Z
|
|
13
|
+
dependencies:
|
|
14
|
+
- !ruby/object:Gem::Dependency
|
|
15
|
+
name: rake
|
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
|
17
|
+
requirements:
|
|
18
|
+
- - ">="
|
|
19
|
+
- !ruby/object:Gem::Version
|
|
20
|
+
version: '0'
|
|
21
|
+
type: :development
|
|
22
|
+
prerelease: false
|
|
23
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
24
|
+
requirements:
|
|
25
|
+
- - ">="
|
|
26
|
+
- !ruby/object:Gem::Version
|
|
27
|
+
version: '0'
|
|
28
|
+
description: Generate memorable random names to use in your apps or anywhere else.
|
|
29
|
+
email:
|
|
30
|
+
- nicu@adoboenterprises.com
|
|
31
|
+
executables: []
|
|
32
|
+
extensions: []
|
|
33
|
+
extra_rdoc_files: []
|
|
34
|
+
files:
|
|
35
|
+
- ".gitignore"
|
|
36
|
+
- ".rspec"
|
|
37
|
+
- ".rubocop.yml"
|
|
38
|
+
- Gemfile
|
|
39
|
+
- LICENSE.txt
|
|
40
|
+
- README.md
|
|
41
|
+
- Rakefile
|
|
42
|
+
- lib/tagalog_haikunator.rb
|
|
43
|
+
- lib/tagalog_haikunator/version.rb
|
|
44
|
+
- tagalog_haikunator.gemspec
|
|
45
|
+
homepage: https://github.com/adobocorp/tagalog-haikunator
|
|
46
|
+
licenses:
|
|
47
|
+
- MIT
|
|
48
|
+
metadata: {}
|
|
49
|
+
post_install_message:
|
|
50
|
+
rdoc_options: []
|
|
51
|
+
require_paths:
|
|
52
|
+
- lib
|
|
53
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
|
54
|
+
requirements:
|
|
55
|
+
- - ">="
|
|
56
|
+
- !ruby/object:Gem::Version
|
|
57
|
+
version: '0'
|
|
58
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
59
|
+
requirements:
|
|
60
|
+
- - ">="
|
|
61
|
+
- !ruby/object:Gem::Version
|
|
62
|
+
version: '0'
|
|
63
|
+
requirements: []
|
|
64
|
+
rubygems_version: 3.4.19
|
|
65
|
+
signing_key:
|
|
66
|
+
specification_version: 4
|
|
67
|
+
summary: Heroku-like random name generator with Tagalog adjectives.
|
|
68
|
+
test_files: []
|