class Codeowners::Cli::Base
Base
collects shared methods used by all CLI sub commands It loads and validate the default config file or output an explanation about how to configure it.
Attributes
config[R]
Public Class Methods
new(args = [], options = {}, config = {})
click to toggle source
Calls superclass method
# File lib/codeowners/cli/base.rb, line 14 def initialize(args = [], options = {}, config = {}) super @config ||= config[:config] || default_config Warner.check_warnings end
Private Instance Methods
default_config()
click to toggle source
# File lib/codeowners/cli/base.rb, line 24 def default_config Codeowners::Config.new end
help_stderr()
click to toggle source
# File lib/codeowners/cli/base.rb, line 28 def help_stderr save_stdout = $stdout $stdout = $stderr help $stdout = save_stdout end