Sha256: 20200c49690c0c0270ec0e72eb87d14a8d9879287b02d89027d74ed0d1616a4d
Contents?: true
Size: 746 Bytes
Versions: 298
Compression:
Stored size: 746 Bytes
Contents
require "appsignal/cli/helpers" module CLIHelpers def cli Appsignal::CLI end def run_cli(command, options = {}) cli.run(format_cli_arguments_and_options(command, options)) end def format_cli_arguments_and_options(command, options = {}) [*command].tap do |o| options.each do |key, value| o << (value.nil? ? "--#{key}" : "--#{key}=#{value}") end end end def add_cli_input(value) $stdin.puts value end def prepare_cli_input # Prepare the input by rewinding the pointer in the StringIO $stdin.rewind end def colorize(*args) ColorizeHelper.colorize(*args) end end module ColorizeHelper extend Appsignal::CLI::Helpers def self.colorize(*_args) super end end
Version data entries
298 entries across 298 versions & 1 rubygems