Class: BundlerSkills::CLI::OverrideDryRun
- Inherits:
-
Object
- Object
- BundlerSkills::CLI::OverrideDryRun
- Defined in:
- lib/bundler_skills/cli.rb
Overview
Wraps a Config to force dry_run? true without mutating the original.
Instance Method Summary collapse
- #dry_run? ⇒ Boolean
-
#initialize(config) ⇒ OverrideDryRun
constructor
A new instance of OverrideDryRun.
- #method_missing(name, *args, &block) ⇒ Object
- #respond_to_missing?(name, include_private = false) ⇒ Boolean
Constructor Details
#initialize(config) ⇒ OverrideDryRun
Returns a new instance of OverrideDryRun.
133 134 135 |
# File 'lib/bundler_skills/cli.rb', line 133 def initialize(config) @config = config end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args, &block) ⇒ Object
145 146 147 |
# File 'lib/bundler_skills/cli.rb', line 145 def method_missing(name, *args, &block) @config.send(name, *args, &block) end |
Instance Method Details
#dry_run? ⇒ Boolean
137 138 139 |
# File 'lib/bundler_skills/cli.rb', line 137 def dry_run? true end |
#respond_to_missing?(name, include_private = false) ⇒ Boolean
141 142 143 |
# File 'lib/bundler_skills/cli.rb', line 141 def respond_to_missing?(name, include_private = false) @config.respond_to?(name, include_private) || super end |