rubiderella 0.1.1 → 0.1.2
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/CHANGELOG.md +18 -0
- data/Gemfile.lock +1 -1
- data/config/assistant/senkawa_chihiro.yml +25 -0
- data/config/trainer/master_trainer.yml +24 -0
- data/config/trainer/rookie_trainer.yml +24 -0
- data/config/trainer/trainer.yml +24 -0
- data/config/trainer/veteran_trainer.yml +24 -0
- data/lib/cinderella_girls.rb +8 -0
- data/lib/cinderella_girls/assistant.rb +15 -0
- data/lib/cinderella_girls/trainer.rb +15 -0
- data/lib/rubiderella.rb +12 -0
- data/lib/rubiderella/assistant.rb +19 -0
- data/lib/rubiderella/assistant/birthday.rb +8 -0
- data/lib/rubiderella/assistant/name.rb +8 -0
- data/lib/rubiderella/errors.rb +7 -0
- data/lib/rubiderella/idol.rb +4 -44
- data/lib/rubiderella/idol/birthday.rb +1 -11
- data/lib/rubiderella/idol/name.rb +1 -17
- data/lib/rubiderella/person.rb +51 -0
- data/lib/rubiderella/person/birthday.rb +18 -0
- data/lib/rubiderella/person/name.rb +24 -0
- data/lib/rubiderella/trainer.rb +19 -0
- data/lib/rubiderella/trainer/birthday.rb +8 -0
- data/lib/rubiderella/trainer/name.rb +8 -0
- data/lib/rubiderella/version.rb +1 -1
- data/rubiderella.gemspec +1 -1
- metadata +20 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a645ccea51cb5c049e586307fc207e426d86e56ed4e245ac0798240a2b51ce60
|
4
|
+
data.tar.gz: 8972fbd5d694118572914176e61578e48d5182c118afb61a7e6c14dc54af39de
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: be24c8fef6dc9077f1a8e2d28e10cbd76410877db86afd89c98dadab0fcbdfda7de7333221b01f0740cf3eccb4497e27ee4516ac7b8eb715329b00573a228a20
|
7
|
+
data.tar.gz: 45a94797a1644c54ded88aee486c55adc70f4989eae70b043d062a36f938aa237aa2d002af2194c294dcdb6a0159a69d140b204820116bed5b452564673ff9c9
|
data/CHANGELOG.md
CHANGED
@@ -0,0 +1,18 @@
|
|
1
|
+
# v0.1.2
|
2
|
+
|
3
|
+
[Full Changelog](https://github.com/hikko624/rubiderella/compare/v0.1.1...v0.1.2)
|
4
|
+
|
5
|
+
- bug fix
|
6
|
+
- add assistant(chihiro-san) and trainer sisters
|
7
|
+
- https://github.com/hikko624/rubiderella/pull/39
|
8
|
+
- https://github.com/hikko624/rubiderella/pull/40
|
9
|
+
|
10
|
+
# v0.1.1
|
11
|
+
|
12
|
+
[Full Changelog](https://github.com/hikko624/rubiderella/compare/v0.1.0...v0.1.1)
|
13
|
+
|
14
|
+
- bug fix
|
15
|
+
- https://github.com/hikko624/rubiderella/pull/35
|
16
|
+
|
17
|
+
# v0.1.0
|
18
|
+
- first release
|
data/Gemfile.lock
CHANGED
@@ -0,0 +1,25 @@
|
|
1
|
+
---
|
2
|
+
senkawa_chihiro:
|
3
|
+
name:
|
4
|
+
last: 千川
|
5
|
+
last_kana: せんかわ
|
6
|
+
first: ちひろ
|
7
|
+
first_kana: ちひろ
|
8
|
+
type: ~
|
9
|
+
age: ??
|
10
|
+
birthday:
|
11
|
+
month: 11
|
12
|
+
day: 28
|
13
|
+
sign: 射手座
|
14
|
+
blood: A
|
15
|
+
height: 154.0
|
16
|
+
weight: ひ・み・つ
|
17
|
+
bust: 82.0
|
18
|
+
waist: 58.0
|
19
|
+
hip: 84.0
|
20
|
+
handed: right
|
21
|
+
from: 東京都
|
22
|
+
favorite:
|
23
|
+
- コスプレ
|
24
|
+
- パーティ
|
25
|
+
cv: 佐藤利奈
|
@@ -0,0 +1,24 @@
|
|
1
|
+
---
|
2
|
+
master_trainer:
|
3
|
+
name:
|
4
|
+
last: 青木
|
5
|
+
last_kana: あおき
|
6
|
+
first: 麗
|
7
|
+
first_kana: れい
|
8
|
+
type: passion
|
9
|
+
age: 28
|
10
|
+
birthday:
|
11
|
+
month: 12
|
12
|
+
day: 10
|
13
|
+
sign: 射手座
|
14
|
+
blood: AB
|
15
|
+
height: 166.0
|
16
|
+
weight: 45.0
|
17
|
+
bust: 82.0
|
18
|
+
waist: 56.0
|
19
|
+
hip: 83.0
|
20
|
+
handed: right
|
21
|
+
from: 栃木県
|
22
|
+
favorite:
|
23
|
+
- スポーツドリンクの自作
|
24
|
+
cv: 藤村歩
|
@@ -0,0 +1,24 @@
|
|
1
|
+
---
|
2
|
+
rookie_trainer:
|
3
|
+
name:
|
4
|
+
last: 青木
|
5
|
+
last_kana: あおき
|
6
|
+
first: 慶
|
7
|
+
first_kana: けい
|
8
|
+
type: passion
|
9
|
+
age: 19
|
10
|
+
birthday:
|
11
|
+
month: 3
|
12
|
+
day: 10
|
13
|
+
sign: 魚座
|
14
|
+
blood: B
|
15
|
+
height: 157.0
|
16
|
+
weight: 45.0
|
17
|
+
bust: 77.0
|
18
|
+
waist: 56.0
|
19
|
+
hip: 82.0
|
20
|
+
handed: right
|
21
|
+
from: 栃木県
|
22
|
+
favorite:
|
23
|
+
- ジム通い
|
24
|
+
cv: 藤村歩
|
@@ -0,0 +1,24 @@
|
|
1
|
+
---
|
2
|
+
trainer:
|
3
|
+
name:
|
4
|
+
last: 青木
|
5
|
+
last_kana: あおき
|
6
|
+
first: 明
|
7
|
+
first_kana: めい
|
8
|
+
type: passion
|
9
|
+
age: 23
|
10
|
+
birthday:
|
11
|
+
month: 6
|
12
|
+
day: 10
|
13
|
+
sign: 双子座
|
14
|
+
blood: B
|
15
|
+
height: 160.0
|
16
|
+
weight: 45.0
|
17
|
+
bust: 84.0
|
18
|
+
waist: 56.0
|
19
|
+
hip: 85.0
|
20
|
+
handed: right
|
21
|
+
from: 栃木県
|
22
|
+
favorite:
|
23
|
+
- 早朝ランニング
|
24
|
+
cv: 藤村歩
|
@@ -0,0 +1,24 @@
|
|
1
|
+
---
|
2
|
+
veteran_trainer:
|
3
|
+
name:
|
4
|
+
last: 青木
|
5
|
+
last_kana: あおき
|
6
|
+
first: 聖
|
7
|
+
first_kana: せい
|
8
|
+
type: passion
|
9
|
+
age: 26
|
10
|
+
birthday:
|
11
|
+
month: 9
|
12
|
+
day: 10
|
13
|
+
sign: 乙女座
|
14
|
+
blood: A
|
15
|
+
height: 163.0
|
16
|
+
weight: 45.0
|
17
|
+
bust: 83.0
|
18
|
+
waist: 56.0
|
19
|
+
hip: 84.0
|
20
|
+
handed: right
|
21
|
+
from: 栃木県
|
22
|
+
favorite:
|
23
|
+
- デイトレード
|
24
|
+
cv: 藤村歩
|
data/lib/cinderella_girls.rb
CHANGED
@@ -0,0 +1,15 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CinderellaGirls
|
4
|
+
class Assistant
|
5
|
+
Rubiderella::Assistant.names.each do |name|
|
6
|
+
define_singleton_method name do
|
7
|
+
Rubiderella::Assistant.find_by_key(name)
|
8
|
+
end
|
9
|
+
end
|
10
|
+
|
11
|
+
def self.all
|
12
|
+
Rubiderella::Assistant.all
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -0,0 +1,15 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module CinderellaGirls
|
4
|
+
class Trainer
|
5
|
+
Rubiderella::Trainer.names.each do |name|
|
6
|
+
define_singleton_method name do
|
7
|
+
Rubiderella::Trainer.find_by_key(name)
|
8
|
+
end
|
9
|
+
end
|
10
|
+
|
11
|
+
def self.all
|
12
|
+
Rubiderella::Trainer.all
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
data/lib/rubiderella.rb
CHANGED
@@ -2,9 +2,21 @@
|
|
2
2
|
|
3
3
|
require 'active_support/all'
|
4
4
|
require 'yaml'
|
5
|
+
require 'rubiderella/person'
|
6
|
+
require 'rubiderella/person/name'
|
7
|
+
require 'rubiderella/person/birthday'
|
8
|
+
require 'rubiderella/assistant'
|
9
|
+
require 'rubiderella/assistant/name'
|
10
|
+
require 'rubiderella/assistant/birthday'
|
11
|
+
require 'rubiderella/errors'
|
5
12
|
require 'rubiderella/idol'
|
6
13
|
require 'rubiderella/idol/name'
|
7
14
|
require 'rubiderella/idol/birthday'
|
15
|
+
require 'rubiderella/trainer'
|
16
|
+
require 'rubiderella/trainer/name'
|
17
|
+
require 'rubiderella/trainer/birthday'
|
8
18
|
require 'rubiderella/version'
|
9
19
|
require 'cinderella_girls'
|
20
|
+
require 'cinderella_girls/assistant'
|
10
21
|
require 'cinderella_girls/idol'
|
22
|
+
require 'cinderella_girls/trainer'
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Rubiderella
|
4
|
+
class Assistant < Person
|
5
|
+
class << self
|
6
|
+
def config
|
7
|
+
@config = Dir.glob("#{File.dirname(__FILE__)}/../../config/assistant/*.yml").each_with_object({}) do |file, idols|
|
8
|
+
idols.merge!(YAML.load_file(file))
|
9
|
+
end.deep_symbolize_keys
|
10
|
+
end
|
11
|
+
|
12
|
+
def find_by_key(key)
|
13
|
+
raise UnknownAssistantError unless valid?(key)
|
14
|
+
|
15
|
+
new(@config[key])
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
data/lib/rubiderella/idol.rb
CHANGED
@@ -1,32 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
module Rubiderella
|
4
|
-
class Idol
|
5
|
-
attr_reader :name, :type, :age, :birthday, :sign, :blood, :height, :weight, :bust, :waist, :hip, :handed, :from,
|
6
|
-
:favorite, :cv
|
7
|
-
@config = nil
|
8
|
-
@all = nil
|
9
|
-
|
10
|
-
def initialize(args)
|
11
|
-
@name = Name.new(args[:name])
|
12
|
-
@type = args[:type]
|
13
|
-
@age = args[:age]
|
14
|
-
@birthday = Birthday.new(args[:birthday])
|
15
|
-
@sign = args[:sign]
|
16
|
-
@blood = args[:blood]
|
17
|
-
@height = args[:height]
|
18
|
-
@weight = args[:weight]
|
19
|
-
@bust = args[:bust]
|
20
|
-
@waist = args[:waist]
|
21
|
-
@hip = args[:hip]
|
22
|
-
@handed = args[:handed]
|
23
|
-
@from = args[:from]
|
24
|
-
@favorite = args[:favorite]
|
25
|
-
@cv = args[:cv]
|
26
|
-
end
|
27
|
-
|
28
|
-
class UnknownIdolError < StandardError; end
|
29
|
-
|
4
|
+
class Idol < Person
|
30
5
|
class << self
|
31
6
|
def config
|
32
7
|
@config = Dir.glob("#{File.dirname(__FILE__)}/../../config/idols/*.yml").each_with_object({}) do |file, idols|
|
@@ -34,25 +9,10 @@ module Rubiderella
|
|
34
9
|
end.deep_symbolize_keys
|
35
10
|
end
|
36
11
|
|
37
|
-
def
|
38
|
-
|
39
|
-
end
|
40
|
-
|
41
|
-
def valid?(idol_name)
|
42
|
-
names.include?(idol_name)
|
43
|
-
end
|
44
|
-
|
45
|
-
def all
|
46
|
-
@all = config.map do |key, value|
|
47
|
-
value[:key] = key
|
48
|
-
new(**value)
|
49
|
-
end
|
50
|
-
end
|
51
|
-
|
52
|
-
def find_by_key(name)
|
53
|
-
raise UnknownIdolError unless valid?(name)
|
12
|
+
def find_by_key(key)
|
13
|
+
raise UnknownIdolError unless valid?(key)
|
54
14
|
|
55
|
-
new(@config[
|
15
|
+
new(@config[key])
|
56
16
|
end
|
57
17
|
end
|
58
18
|
end
|
@@ -2,17 +2,7 @@
|
|
2
2
|
|
3
3
|
module Rubiderella
|
4
4
|
class Idol
|
5
|
-
class Birthday
|
6
|
-
attr_reader :month, :day
|
7
|
-
|
8
|
-
def initialize(args)
|
9
|
-
@month = args[:month]
|
10
|
-
@day = args[:day]
|
11
|
-
end
|
12
|
-
|
13
|
-
def date
|
14
|
-
@month.to_s + '月' + @day.to_s + '日'
|
15
|
-
end
|
5
|
+
class Birthday < Person::Birthday
|
16
6
|
end
|
17
7
|
end
|
18
8
|
end
|
@@ -2,23 +2,7 @@
|
|
2
2
|
|
3
3
|
module Rubiderella
|
4
4
|
class Idol
|
5
|
-
class Name
|
6
|
-
attr_reader :last, :last_kana, :first, :first_kana
|
7
|
-
|
8
|
-
def initialize(args)
|
9
|
-
@last = args[:last]
|
10
|
-
@last_kana = args[:last_kana]
|
11
|
-
@first = args[:first]
|
12
|
-
@first_kana = args[:first_kana]
|
13
|
-
end
|
14
|
-
|
15
|
-
def full
|
16
|
-
@last + @first
|
17
|
-
end
|
18
|
-
|
19
|
-
def full_kana
|
20
|
-
@last_kana + @first_kana
|
21
|
-
end
|
5
|
+
class Name < Person::Name
|
22
6
|
end
|
23
7
|
end
|
24
8
|
end
|
@@ -0,0 +1,51 @@
|
|
1
|
+
module Rubiderella
|
2
|
+
class Person
|
3
|
+
attr_reader :name, :type, :age, :birthday, :sign, :blood, :height, :weight, :bust, :waist, :hip, :handed, :from,
|
4
|
+
:favorite, :cv
|
5
|
+
@config = nil
|
6
|
+
@all = nil
|
7
|
+
|
8
|
+
def initialize(args)
|
9
|
+
@name = Name.new(args[:name])
|
10
|
+
@type = args[:type]
|
11
|
+
@age = args[:age]
|
12
|
+
@birthday = Birthday.new(args[:birthday])
|
13
|
+
@sign = args[:sign]
|
14
|
+
@blood = args[:blood]
|
15
|
+
@height = args[:height]
|
16
|
+
@weight = args[:weight]
|
17
|
+
@bust = args[:bust]
|
18
|
+
@waist = args[:waist]
|
19
|
+
@hip = args[:hip]
|
20
|
+
@handed = args[:handed]
|
21
|
+
@from = args[:from]
|
22
|
+
@favorite = args[:favorite]
|
23
|
+
@cv = args[:cv]
|
24
|
+
end
|
25
|
+
|
26
|
+
class << self
|
27
|
+
def config
|
28
|
+
raise NotImplementedError
|
29
|
+
end
|
30
|
+
|
31
|
+
def names
|
32
|
+
config.keys
|
33
|
+
end
|
34
|
+
|
35
|
+
def valid?(person_name)
|
36
|
+
names.include?(person_name)
|
37
|
+
end
|
38
|
+
|
39
|
+
def all
|
40
|
+
@all = config.map do |key, value|
|
41
|
+
value[:key] = key
|
42
|
+
new(**value)
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
def find_by_key(key)
|
47
|
+
raise NotImplementedError
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Rubiderella
|
4
|
+
class Person
|
5
|
+
class Birthday
|
6
|
+
attr_reader :month, :day
|
7
|
+
|
8
|
+
def initialize(args)
|
9
|
+
@month = args[:month]
|
10
|
+
@day = args[:day]
|
11
|
+
end
|
12
|
+
|
13
|
+
def date
|
14
|
+
@month.to_s + '月' + @day.to_s + '日'
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Rubiderella
|
4
|
+
class Person
|
5
|
+
class Name
|
6
|
+
attr_reader :last, :last_kana, :first, :first_kana
|
7
|
+
|
8
|
+
def initialize(args)
|
9
|
+
@last = args[:last]
|
10
|
+
@last_kana = args[:last_kana]
|
11
|
+
@first = args[:first]
|
12
|
+
@first_kana = args[:first_kana]
|
13
|
+
end
|
14
|
+
|
15
|
+
def full
|
16
|
+
@last + @first
|
17
|
+
end
|
18
|
+
|
19
|
+
def full_kana
|
20
|
+
@last_kana + @first_kana
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Rubiderella
|
4
|
+
class Trainer < Person
|
5
|
+
class << self
|
6
|
+
def config
|
7
|
+
@config = Dir.glob("#{File.dirname(__FILE__)}/../../config/trainer/*.yml").each_with_object({}) do |file, idols|
|
8
|
+
idols.merge!(YAML.load_file(file))
|
9
|
+
end.deep_symbolize_keys
|
10
|
+
end
|
11
|
+
|
12
|
+
def find_by_key(key)
|
13
|
+
raise UnknownTrainerError unless valid?(key)
|
14
|
+
|
15
|
+
new(@config[key])
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
data/lib/rubiderella/version.rb
CHANGED
data/rubiderella.gemspec
CHANGED
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
|
|
10
10
|
spec.description = 'Idol m@ster cinderella girls starlight stage'
|
11
11
|
spec.homepage = 'https://github.com/hikko624/rubiderella'
|
12
12
|
spec.license = 'MIT'
|
13
|
-
spec.required_ruby_version = Gem::Requirement.new('>= 2.
|
13
|
+
spec.required_ruby_version = Gem::Requirement.new('>= 2.4.0')
|
14
14
|
|
15
15
|
spec.metadata['homepage_uri'] = spec.homepage
|
16
16
|
spec.metadata['source_code_uri'] = spec.homepage
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubiderella
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- hikko624
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-08-
|
11
|
+
date: 2020-08-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -143,6 +143,7 @@ files:
|
|
143
143
|
- Rakefile
|
144
144
|
- bin/console
|
145
145
|
- bin/setup
|
146
|
+
- config/assistant/senkawa_chihiro.yml
|
146
147
|
- config/idols/abe_nana.yml
|
147
148
|
- config/idols/aiba_yumi.yml
|
148
149
|
- config/idols/aihara_yukino.yml
|
@@ -333,12 +334,28 @@ files:
|
|
333
334
|
- config/idols/yusa_kozue.yml
|
334
335
|
- config/idols/yuuki_haru.yml
|
335
336
|
- config/idols/zaizen_tokiko.yml
|
337
|
+
- config/trainer/master_trainer.yml
|
338
|
+
- config/trainer/rookie_trainer.yml
|
339
|
+
- config/trainer/trainer.yml
|
340
|
+
- config/trainer/veteran_trainer.yml
|
336
341
|
- lib/cinderella_girls.rb
|
342
|
+
- lib/cinderella_girls/assistant.rb
|
337
343
|
- lib/cinderella_girls/idol.rb
|
344
|
+
- lib/cinderella_girls/trainer.rb
|
338
345
|
- lib/rubiderella.rb
|
346
|
+
- lib/rubiderella/assistant.rb
|
347
|
+
- lib/rubiderella/assistant/birthday.rb
|
348
|
+
- lib/rubiderella/assistant/name.rb
|
349
|
+
- lib/rubiderella/errors.rb
|
339
350
|
- lib/rubiderella/idol.rb
|
340
351
|
- lib/rubiderella/idol/birthday.rb
|
341
352
|
- lib/rubiderella/idol/name.rb
|
353
|
+
- lib/rubiderella/person.rb
|
354
|
+
- lib/rubiderella/person/birthday.rb
|
355
|
+
- lib/rubiderella/person/name.rb
|
356
|
+
- lib/rubiderella/trainer.rb
|
357
|
+
- lib/rubiderella/trainer/birthday.rb
|
358
|
+
- lib/rubiderella/trainer/name.rb
|
342
359
|
- lib/rubiderella/version.rb
|
343
360
|
- rubiderella.gemspec
|
344
361
|
homepage: https://github.com/hikko624/rubiderella
|
@@ -356,7 +373,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
356
373
|
requirements:
|
357
374
|
- - ">="
|
358
375
|
- !ruby/object:Gem::Version
|
359
|
-
version: 2.
|
376
|
+
version: 2.4.0
|
360
377
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
361
378
|
requirements:
|
362
379
|
- - ">="
|