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.
134 135 136 |
# File 'lib/bundler_skills/cli.rb', line 134 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
146 147 148 |
# File 'lib/bundler_skills/cli.rb', line 146 def method_missing(name, *args, &block) @config.send(name, *args, &block) end |
Instance Method Details
#dry_run? ⇒ Boolean
138 139 140 |
# File 'lib/bundler_skills/cli.rb', line 138 def dry_run? true end |
#respond_to_missing?(name, include_private = false) ⇒ Boolean
142 143 144 |
# File 'lib/bundler_skills/cli.rb', line 142 def respond_to_missing?(name, include_private = false) @config.respond_to?(name, include_private) || super end |