Class: GemBootstrap::Configuration Private
- Inherits:
-
Object
- Object
- GemBootstrap::Configuration
- Defined in:
- lib/gem-bootstrap/configuration.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Instance Attribute Summary collapse
- #author_email ⇒ String readonly private
- #author_name ⇒ String readonly private
- #changelog_url ⇒ String readonly private
- #docs_url ⇒ String readonly private
- #gem_name ⇒ String readonly private
- #github_repo ⇒ String readonly private
- #github_url ⇒ String readonly private
- #github_username ⇒ String readonly private
- #gitter_url ⇒ String readonly private
- #module_name ⇒ String readonly private
- #project_name ⇒ String readonly private
- #project_summary ⇒ String readonly private
- #year ⇒ Integer readonly private
Class Method Summary collapse
- .build(options) ⇒ Object private
Instance Method Summary collapse
-
#initialize(project_name:, module_name:, gem_name:, author_name:, author_email:, github_username:) ⇒ Configuration
constructor
private
A new instance of Configuration.
Constructor Details
#initialize(project_name:, module_name:, gem_name:, author_name:, author_email:, github_username:) ⇒ Configuration
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of Configuration.
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/gem-bootstrap/configuration.rb', line 9 def initialize( project_name:, module_name:, gem_name:, author_name:, author_email:, github_username: ) @project_name = project_name @module_name = module_name @gem_name = gem_name @author_name = @author_email = @project_summary = project_name @github_username = github_username @github_repo = "#{github_username}/#{gem_name}" @year = Time.now.utc.year @docs_url = "https://www.rubydoc.info/github/#{github_repo}/master" @gitter_url = "https://gitter.im/#{github_username}" @github_url = "https://github.com/#{github_repo}" @changelog_url = @github_url + '/blob/master/CHANGELOG.md' end |
Instance Attribute Details
#author_email ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
48 49 50 |
# File 'lib/gem-bootstrap/configuration.rb', line 48 def @author_email end |
#author_name ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
45 46 47 |
# File 'lib/gem-bootstrap/configuration.rb', line 45 def @author_name end |
#changelog_url ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
69 70 71 |
# File 'lib/gem-bootstrap/configuration.rb', line 69 def changelog_url @changelog_url end |
#docs_url ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
60 61 62 |
# File 'lib/gem-bootstrap/configuration.rb', line 60 def docs_url @docs_url end |
#gem_name ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
42 43 44 |
# File 'lib/gem-bootstrap/configuration.rb', line 42 def gem_name @gem_name end |
#github_repo ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
54 55 56 |
# File 'lib/gem-bootstrap/configuration.rb', line 54 def github_repo @github_repo end |
#github_url ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
66 67 68 |
# File 'lib/gem-bootstrap/configuration.rb', line 66 def github_url @github_url end |
#github_username ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
51 52 53 |
# File 'lib/gem-bootstrap/configuration.rb', line 51 def github_username @github_username end |
#gitter_url ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
63 64 65 |
# File 'lib/gem-bootstrap/configuration.rb', line 63 def gitter_url @gitter_url end |
#module_name ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
39 40 41 |
# File 'lib/gem-bootstrap/configuration.rb', line 39 def module_name @module_name end |
#project_name ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
33 34 35 |
# File 'lib/gem-bootstrap/configuration.rb', line 33 def project_name @project_name end |
#project_summary ⇒ String (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
36 37 38 |
# File 'lib/gem-bootstrap/configuration.rb', line 36 def project_summary @project_summary end |
#year ⇒ Integer (readonly)
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
57 58 59 |
# File 'lib/gem-bootstrap/configuration.rb', line 57 def year @year end |
Class Method Details
.build(options) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
74 75 76 77 78 79 80 81 82 83 84 |
# File 'lib/gem-bootstrap/configuration.rb', line 74 def build() gem_name = .arguments.first new( project_name: project_name(gem_name), module_name: module_name(gem_name), gem_name: gem_name, author_name: (), author_email: email(), github_username: [:github_username] ) end |