randomperson 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +2 -0
- data/Manifest +0 -2
- data/Rakefile +1 -1
- data/lib/NameFiles/AmericanMaleFirst.rb +1 -1
- data/lib/NameFiles/BasqueLast.rb +1 -0
- data/lib/NameFiles/SwedishFemaleFirst.rb +1 -0
- data/lib/NameFiles/SwedishLast.rb +2 -1
- data/lib/NameFiles/SwedishMaleFirst.rb +1 -0
- data/lib/NameFiles/ThaiFirst.rb +1 -0
- data/lib/NameFiles/ThaiRomanisedFemaleFirst.rb +1 -0
- data/lib/NameFiles/ThaiRomanisedLast.rb +1 -0
- data/lib/NameFiles/ThaiRomanisedMaleFirst.rb +1 -0
- data/randomperson.gemspec +3 -3
- data.tar.gz.sig +0 -0
- metadata +2 -6
- metadata.gz.sig +0 -0
- data/lib/CommonFormatsFirstName.rb +0 -38
- data/lib/Formatter.rb +0 -31
data/CHANGELOG
CHANGED
data/Manifest
CHANGED
data/Rakefile
CHANGED
@@ -14,7 +14,7 @@ module RandomPerson
|
|
14
14
|
end
|
15
15
|
|
16
16
|
def setupnames
|
17
|
-
|
17
|
+
@names = %w{ Aaron Adam Adrian Alan Alejandro Alex Allen Andrew Andy Anthony Art Arthur Barry Bart Ben Benjamin Bill Bobby Brad Bradley Brendan Brett Brian Bruce Bryan Carlos Chad Charles Chris Christopher Chuck Clay Corey Craig Dan Daniel Darren Dave David Dean Dennis Denny Derek Don Doug Duane Edward Eric Eugene Evan Frank Fred Gary Gene George Gordon Greg Harry Henry Hunter Ivan Jack James Jamie Jason Jay Jeff Jeffrey Jeremy Jim Joe Joel John Jonathan Joseph Justin Keith Ken Kevin Larry Logan Marc Mark Matt Matthew Michael Mike Nat Nathan Patrick Paul Perry Peter Philip Phillip Randy Raymond Ricardo Richard Rick Rob Robert Rod Roger Ross Ruben Russell Ryan Sam Scot Scott Sean Shaun Stephen Steve Steven Stewart Stuart Ted Thomas Tim Toby Todd Tom Troy Victor Wade Walter Wayne William }
|
18
18
|
end
|
19
19
|
|
20
20
|
end
|
data/lib/NameFiles/BasqueLast.rb
CHANGED
@@ -11,11 +11,12 @@ module RandomPerson
|
|
11
11
|
}
|
12
12
|
|
13
13
|
@formats_ratiod = [ (0..99)]
|
14
|
+
setupnames
|
14
15
|
end
|
15
16
|
|
16
17
|
|
17
18
|
def setupnames
|
18
|
-
|
19
|
+
@names = %w{ Johansson Andersson Karlsson Nilsson Eriksson Larsson Olsson Persson Svensson Gustafsson Pettersson Jonsson Jansson Hansson Bengtsson Jönsson Petersson Carlsson Lindberg Magnusson Gustavsson Lindström Olofsson Lindgren Axelsson Lundberg Bergström Jakobsson Lundgren Berg Berglund Fredriksson Mattsson Sandberg Henriksson Sjöberg Forsberg Lindqvist Håkansson Engström Danielsson Lind Lundin Eklund Gunnarsson Holm Samuelsson Fransson Johnsson Bergman Holmberg Nyström Lundqvist Arvidsson Björk Isaksson Nyberg Söderberg Mårtensson Wallin Nordström Lundström Eliasson Björklund Berggren Nordin Sandström Ström Hermansson Åberg Ekström Holmgren Sundberg Hedlund Sjögren Martinsson Månsson Dahlberg Öberg Abrahamsson Strömberg Hellström Åkesson Jonasson Blomqvist Blom Norberg Andreasson Sundström Ek Åström Lindholm Göransson Ivarsson Löfgren Söderström Nyman Jensen Falk Bergqvist Lund Dahl Hansen Möller Josefsson Palm Ottosson Hallberg Davidsson Borg Englund Boström Sjöström Adolfsson Söderlund Börjesson Lindblom Ekman Bäckström Nygren Rosén Holmström Höglund Lindahl Hedberg Stenberg Friberg Strand Skoglund Björkman Nielsen Erlandsson Strandberg Johannesson Viklund Ali Aronsson Vikström Edlund Claesson Malm Wikström Lindén Haglund Knutsson Östlund Dahlgren Moberg Norén Melin Pålsson Franzén Holmqvist Dahlström Sundqvist Roos Högberg Lilja Oskarsson Blomberg Alm Öhman Olausson Sundin Hedman Lindell Hedström Lundmark Nord Sjödin Paulsson Boman Ericsson Molin Sköld Pedersen Hagström Ljungberg Näslund Lindblad Svärd Ståhl Ljung Ågren Malmberg Ekberg Linder Hellberg Lindkvist Norman Berntsson Ahmed Wiklund Augustsson Lundkvist Ohlsson Hjalmarsson Törnqvist Kristiansson Wahlström Asplund Andersen Forslund Hedin Fors Brandt Jacobsson Hägglund Dahlin Österberg Edström Torstensson Ahlström Marklund Alfredsson Frisk Niklasson Lindh Klasson Westerlund Bertilsson Backman Lövgren Byström Hall Nordqvist Westerberg Grahn Lindvall Bäckman Larsen Wiberg Nordlund Alexandersson Simonsson Skog Dahlqvist Hagberg Edvardsson Forsman Hjelm Malmström Ljunggren Karlström Östman Westman Ahlberg Sjöblom Granberg Kjellberg Levin Lennartsson Backlund Sjöstrand Emanuelsson Hagman Bergkvist Hellman Ahlgren Rydberg Almqvist Svedberg Holgersson Hallgren Sjöholm Hassan Lundell Antonsson Palmqvist Rosengren Hellgren Ekholm Sahlin Salomonsson Åkerlund Hägg Engman Broberg Bäck Christensen Krantz Nordgren Lindmark Sandin Rydén Hammar Hult Mohamed Lantz Vilhelmsson Malmqvist Westin Ericson Thorén Wahlberg Strid Svanberg Ibrahim Gabrielsson Hultgren Malmgren Sjölund Henningsson Hultman Blomgren Ekstrand Westberg Nylander Vesterlund Jeppsson Svahn Andrén Wall Broman Engberg Östberg Sandgren Karlberg Brännström Engdahl Bodin Asp Ekelund Kristensson Kvist Hallin Haraldsson Nguyen Granström Hammarström Söderqvist Viberg Nordberg Melander Olsen Helgesson Kristoffersson Sandell Burman Eklöf Israelsson Söderholm Norling Sjöstedt Sörensen Forsgren Lindskog Lidén Bolin Vallin Hussein Robertsson Borgström Norrman Einarsson Elofsson Granlund Norgren Häggström Vestin Linde Lindfors Bylund Blixt Turesson Bohlin Gren Brodin Lundblad Edman Ahlqvist Svantesson Sjölin Sjölander Halvarsson Forsell Ekdahl Åslund Löf Almgren Frank Wennberg Skoog Lundh Landin Granath Källström Söderman Green Palmgren Öman Wester Rasmussen Sundell Södergren Östling Lundquist Thulin Lindquist Bergsten Edin Rosenqvist Werner Landström Folkesson Jörgensen Bergvall Blomkvist Holst Stenström Liljegren Lidström Åsberg Ljungqvist Johnson Ahlin Mohammed Widén Nylén Schmidt Anderberg Stark Nordlander Brolin Pihl Petersen Vestman Flink Carlson Kling Norlin Emilsson Edberg Johansen Zetterberg Rasmusson Frid Ingvarsson Engvall Ögren Wahlgren Grönlund Stenlund Lundholm Lönn Birgersson Wilhelmsson Bergstrand Roth Olander Dahlén Westlund Rosenberg Ferm Åkerman Wallgren Tran Wallén Lundahl Åkerström Fagerström Flodin Broström Ragnarsson Carlberg Hjort Holmlund Rask Peterson Gullberg Steen Rehn Ring Österlund Ahl Albertsson Khan Brorsson Nyqvist Juhlin Christensson Sundkvist Hanna Åkerblom Hallström Brink Selin Nylund Jarl Albinsson Thunberg Molander Klang Modig Edvinsson Åman Bohman Bergdahl Carlström Winberg Norin Rylander Bäcklund Boberg Hultberg Fält Thor Smith Forsström Högström Söder Nordén Norström Harrysson Storm Sterner Sandqvist Hurtig Svanström Lindman Sund Bernhardsson Enström Lindeberg Rosell Friman Hellqvist Wallberg Grundström Ask Grönberg Modin Björn Söderlind Fröberg Ekvall Zetterström Risberg Ahmad Selander Vestlund Olovsson Olin Granqvist Sjöqvist Landgren Stenman Christiansson Norell Vestberg Lindroth Wik Abdi Matsson Östergren Sten Renström Viktorsson Joelsson Jernberg Åkerberg Liljedahl Lundén Lager Rydell Thelin Rosberg Ryberg Eskilsson Stensson Nordmark Said Back Berlin Sand Westling Cederholm Bergquist Sjökvist Oscarsson Adamsson Holmkvist Vesterberg Fröjd Hamberg Zetterlund Lundvall Lindstedt Åhman Stenmark Markström Hallén Wallström Malmborg Rosander Öhrn Bergh Lundstedt Kjellgren Åstrand Lindbäck Madsen Ludvigsson Niemi Wang Berndtsson Widell Smedberg Zakrisson Törnblom Ölund Elfström Thorell Kullberg Kvarnström Müller Osman Westergren Thuresson Fast Edholm Sundgren Lööf Engblom Isberg Berglind Beckman Nykvist Palmér Gillberg Fahlén Carlén Frick Dahlman Lagerqvist Filipsson Rundqvist Tell Hammarberg Kristensen Mustafa Löfqvist Fagerberg From Wikman Rapp Ljungdahl Ljungström Rönnqvist Mattisson Arnesson Blomquist Mossberg Collin Källman Näsström Bogren Käll Cederberg Berger Issa Vikman Sturesson Ekblad Bodén Fernström Vedin Schön Helander Bondesson Lidberg Källberg Schultz Kraft Sandén Grip Häll Tapper Törnkvist Ekblom Engstrand Erixon Rahm Sjöö Lundborg Öst Wendel Stolt Mohammad Thorsell Thomasson Ismail Qvist Rosendahl Elfving Nordahl Sonesson Spångberg Holmquist Hedén Evertsson Nordkvist Sandahl Hultin Meijer Leijon Bratt Roslund Omar Ehn Landberg Nelson Gran Helmersson Li Österman Ringström Rosvall Hammarlund Hagelin Bergstedt Leander Fredin Thörn Fogelberg Nordh Olsén Jacobson Engqvist Gudmundsson Almén Trygg Svedin Lidman Lagerström Appelgren Gashi Lagergren Rönnberg Björling Mörk Wickström Bladh Nordvall Mellberg Hultén Wedin Kjellin Malmsten Forss Saleh Wiman Wessman Kron Helin Mikaelsson Nordling Fritz Kallin Hultqvist Holmén Hugosson Ling Fridlund Zhang Sundén Sahlén Morén Säll Hallqvist Zachrisson Norrby Hed Sundman Singh Ljungkvist Brodén Hellsten Runesson Hedqvist Malmros Lindstrand Lindbom Falck Svedlund Nyholm Thorsson Strömbäck Stål Nilsen Sörensson Kempe Hällgren Fagerlund Blad Gradin Ingemarsson Löfstedt Freij Vernersson Aziz Thelander Chen Holmer Kroon Christiansen Fischer Cedergren Sahlberg Eng Krasniqi Ersson Abbas Sundvall Schröder Karlén Morin Löfström Stålnacke Zackrisson Fridén Hjorth Lindborg Kjellström Glad Säfström Landén Norlander Enberg Markusson Brundin Wahlqvist Welander Björck Gidlund Cederlund Lundbäck Stålberg Jacobsen Klint Lejon Wallman Öhlund Vikberg Löfberg Lovén Bjurström Welin Staaf Söderblom Öström Zander Öster Martin Liljekvist Törngren Reinholdsson Stoltz Ceder Lönnqvist Svensk Berisha Sahlström Julin Amin Edgren Forssell Sundelin Rashid Wickman Sander Öhlin Ramström Ramberg Karim Backström Sjödahl Seger Liu Björkqvist Strömgren Stenvall Rickardsson Rydström Lorentzon Hilmersson Chamoun Fahlström Holmstedt Köhler Kruse Fahlgren Wennerberg Meyer André Qvarnström Lang Örn Anderson Enqvist Sjösten Bark Krook Grankvist Blomdahl Demir Petrovic Grönvall Törnberg Georgsson Strömqvist Widmark Rönn Näsman Henrysson Åhlén Benjaminsson Wirén Wihlborg Nordstrand Burström Lange Löfstrand Aho Wass Rundberg Rönnbäck Nygård Stenqvist Becker Classon Linderoth Åhlander Åkerlind Tornberg Käck Thomsen Kihlström Granat Fridh Widlund Björnberg Wennström Fredlund Haag Lönnberg Appelqvist Hjerpe Hemmingsson Jovanovic Högman Kjellman Frost Sunesson Abdullah Laine Algotsson Ulander Hildingsson Bergmark Walter Lång Sundquist Ledin Axén Glans Lahti Yousef Sigfridsson Stefansson Tillberg Farah Höök Klingberg Kihlberg Åhs Kristiansen Leandersson Källgren Kjell Renberg Assarsson Halldin Hassel Sandblom Kjellsson Fjellström Valfridsson Vestling Wilson Yilmaz Hoffman Henning Ohlin Lif Le Ahlstrand Sandelin Alvarsson Vinberg Aldén Björnsson Adler Medin Hedvall }
|
19
20
|
end
|
20
21
|
end
|
21
22
|
end
|
data/lib/NameFiles/ThaiFirst.rb
CHANGED
data/randomperson.gemspec
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
4
|
s.name = %q{randomperson}
|
5
|
-
s.version = "0.0.
|
5
|
+
s.version = "0.0.3"
|
6
6
|
|
7
7
|
s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
|
8
8
|
s.authors = ["Iain Barnett"]
|
@@ -10,8 +10,8 @@ Gem::Specification.new do |s|
|
|
10
10
|
s.date = %q{2010-08-24}
|
11
11
|
s.description = %q{A gem for generating random persons}
|
12
12
|
s.email = %q{iainspeed @nospam@ gmail.com}
|
13
|
-
s.extra_rdoc_files = ["CHANGELOG", "README", "lib/Choice.rb", "lib/
|
14
|
-
s.files = ["CHANGELOG", "Manifest", "README", "Rakefile", "gem-public_cert.pem", "lib/Choice.rb", "lib/
|
13
|
+
s.extra_rdoc_files = ["CHANGELOG", "README", "lib/Choice.rb", "lib/Generator.rb", "lib/Name.rb", "lib/NameFiles/AmericanLast.rb", "lib/NameFiles/AmericanMaleFirst.rb", "lib/NameFiles/AmericanSuffix.rb", "lib/NameFiles/AnyLast.rb", "lib/NameFiles/BasqueLast.rb", "lib/NameFiles/BritishPrefix.rb", "lib/NameFiles/BritishSuffix.rb", "lib/NameFiles/EnglishFemaleFirst.rb", "lib/NameFiles/EnglishLast.rb", "lib/NameFiles/EnglishMaleFirst.rb", "lib/NameFiles/ScottishFemaleFirst.rb", "lib/NameFiles/ScottishLast.rb", "lib/NameFiles/ScottishMaleFirst.rb", "lib/NameFiles/SpanishFemaleFirst.rb", "lib/NameFiles/SpanishLast.rb", "lib/NameFiles/SpanishMaleFirst.rb", "lib/NameFiles/SwedishFemaleFirst.rb", "lib/NameFiles/SwedishLast.rb", "lib/NameFiles/SwedishMaleFirst.rb", "lib/NameFiles/ThaiFirst.rb", "lib/NameFiles/ThaiRomanisedFemaleFirst.rb", "lib/NameFiles/ThaiRomanisedLast.rb", "lib/NameFiles/ThaiRomanisedMaleFirst.rb", "lib/NameFiles/WelshFemaleFirst.rb", "lib/NameFiles/WelshLast.rb", "lib/NameFiles/WelshMaleFirst.rb", "lib/Names.rb", "lib/Person.rb", "lib/Ratio.rb", "lib/ext/Array.rb", "lib/ext/Date.rb", "lib/ext/Enumerable.rb", "lib/ext/Hash.rb", "lib/ext/Kernel.rb", "lib/ext/Set.rb", "lib/randomperson.rb"]
|
14
|
+
s.files = ["CHANGELOG", "Manifest", "README", "Rakefile", "gem-public_cert.pem", "lib/Choice.rb", "lib/Generator.rb", "lib/Name.rb", "lib/NameFiles/AmericanLast.rb", "lib/NameFiles/AmericanMaleFirst.rb", "lib/NameFiles/AmericanSuffix.rb", "lib/NameFiles/AnyLast.rb", "lib/NameFiles/BasqueLast.rb", "lib/NameFiles/BritishPrefix.rb", "lib/NameFiles/BritishSuffix.rb", "lib/NameFiles/EnglishFemaleFirst.rb", "lib/NameFiles/EnglishLast.rb", "lib/NameFiles/EnglishMaleFirst.rb", "lib/NameFiles/ScottishFemaleFirst.rb", "lib/NameFiles/ScottishLast.rb", "lib/NameFiles/ScottishMaleFirst.rb", "lib/NameFiles/SpanishFemaleFirst.rb", "lib/NameFiles/SpanishLast.rb", "lib/NameFiles/SpanishMaleFirst.rb", "lib/NameFiles/SwedishFemaleFirst.rb", "lib/NameFiles/SwedishLast.rb", "lib/NameFiles/SwedishMaleFirst.rb", "lib/NameFiles/ThaiFirst.rb", "lib/NameFiles/ThaiRomanisedFemaleFirst.rb", "lib/NameFiles/ThaiRomanisedLast.rb", "lib/NameFiles/ThaiRomanisedMaleFirst.rb", "lib/NameFiles/WelshFemaleFirst.rb", "lib/NameFiles/WelshLast.rb", "lib/NameFiles/WelshMaleFirst.rb", "lib/Names.rb", "lib/Person.rb", "lib/Ratio.rb", "lib/ext/Array.rb", "lib/ext/Date.rb", "lib/ext/Enumerable.rb", "lib/ext/Hash.rb", "lib/ext/Kernel.rb", "lib/ext/Set.rb", "lib/randomperson.rb", "t/Generator.t", "randomperson.gemspec"]
|
15
15
|
s.homepage = %q{http://github.com/yb66/RandomPerson}
|
16
16
|
s.rdoc_options = ["--line-numbers", "--inline-source", "--title", "Randomperson", "--main", "README"]
|
17
17
|
s.require_paths = ["lib"]
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
|
|
5
5
|
segments:
|
6
6
|
- 0
|
7
7
|
- 0
|
8
|
-
-
|
9
|
-
version: 0.0.
|
8
|
+
- 3
|
9
|
+
version: 0.0.3
|
10
10
|
platform: ruby
|
11
11
|
authors:
|
12
12
|
- Iain Barnett
|
@@ -49,8 +49,6 @@ extra_rdoc_files:
|
|
49
49
|
- CHANGELOG
|
50
50
|
- README
|
51
51
|
- lib/Choice.rb
|
52
|
-
- lib/CommonFormatsFirstName.rb
|
53
|
-
- lib/Formatter.rb
|
54
52
|
- lib/Generator.rb
|
55
53
|
- lib/Name.rb
|
56
54
|
- lib/NameFiles/AmericanLast.rb
|
@@ -96,8 +94,6 @@ files:
|
|
96
94
|
- Rakefile
|
97
95
|
- gem-public_cert.pem
|
98
96
|
- lib/Choice.rb
|
99
|
-
- lib/CommonFormatsFirstName.rb
|
100
|
-
- lib/Formatter.rb
|
101
97
|
- lib/Generator.rb
|
102
98
|
- lib/Name.rb
|
103
99
|
- lib/NameFiles/AmericanLast.rb
|
metadata.gz.sig
CHANGED
Binary file
|
@@ -1,38 +0,0 @@
|
|
1
|
-
module RandomPerson
|
2
|
-
|
3
|
-
require 'Names'
|
4
|
-
|
5
|
-
class FirstName
|
6
|
-
include Names
|
7
|
-
|
8
|
-
#def names() NAMES; end
|
9
|
-
|
10
|
-
def initialize
|
11
|
-
@formats = {
|
12
|
-
:single => ->(n) { n.rand },
|
13
|
-
}
|
14
|
-
|
15
|
-
@formats_ratiod = [ (0..99)]
|
16
|
-
end
|
17
|
-
|
18
|
-
attr_accessor :formats, :formats_ratiod
|
19
|
-
|
20
|
-
def execute( person, format=nil, names )
|
21
|
-
if format.nil?
|
22
|
-
if @formats.length > 1
|
23
|
-
r = rand(@formats_ratiod.last.end)
|
24
|
-
i = @formats_ratiod.index_in_range( r )
|
25
|
-
f = @formats.by_index(i).last
|
26
|
-
else
|
27
|
-
f = @formats[:single]
|
28
|
-
end
|
29
|
-
else
|
30
|
-
f = format
|
31
|
-
end
|
32
|
-
format = ->(n){ n.rand } if format.nil?
|
33
|
-
# puts format.inspect
|
34
|
-
format.( names )
|
35
|
-
end
|
36
|
-
|
37
|
-
end
|
38
|
-
end
|
data/lib/Formatter.rb
DELETED
@@ -1,31 +0,0 @@
|
|
1
|
-
#!/usr/bin/env ruby -wKU
|
2
|
-
|
3
|
-
module RandomPerson
|
4
|
-
|
5
|
-
class Formatter
|
6
|
-
|
7
|
-
def initialize( extra={} )
|
8
|
-
@@formats = {
|
9
|
-
:single => ->(n){ n.rand },
|
10
|
-
:double_barrelled => ->(n){ n.rand + ' ' + n.rand },
|
11
|
-
:double_barrelled => ->(n){ n.rand + ' ' + n.rand },
|
12
|
-
:de => ->(n){ n.rand + ' de ' + n.rand },
|
13
|
-
:compound_hyphenated => ->(n){ n.rand + ' ' + n.rand + ' ' + n.rand },
|
14
|
-
:compound_y => ->(n){ n.rand + ' ' + n.rand + ' y ' + n.rand },
|
15
|
-
}
|
16
|
-
|
17
|
-
self.formats=( extra ) unless extra.empty?
|
18
|
-
end
|
19
|
-
|
20
|
-
def formats
|
21
|
-
return @@formats
|
22
|
-
end
|
23
|
-
|
24
|
-
def formats=(extra={})
|
25
|
-
@@formats.merge!( extra ) unless extra.empty?
|
26
|
-
end
|
27
|
-
end
|
28
|
-
|
29
|
-
|
30
|
-
end
|
31
|
-
|