Sha256: 7aebe8c4dab7fa132605de3a27443b72532d59105342ea340107016714f92f35
Contents?: true
Size: 897 Bytes
Versions: 33
Compression:
Stored size: 897 Bytes
Contents
require "paint" module SiteHook class SiteHookError < StandardError attr :err, :status def initialize(msg, err) @err = err @status = @err super(msg) end end class ConfigExistsError < SiteHookError end class NoConfigError < SiteHookError attr_reader :path def initialize(path) @str = "Config path '#{Paint[path, "red"]}' does not exist!" @path = Pathname.new(path) super(@str, 98) end end class NeitherConfigError < SiteHookError attr_reader :paths def initialize @str = "Neither '#{SiteHook::Paths.old_config}' nor '#{SiteHook::Paths.config}'" super(@str, 99) end end class NoLogsError < SiteHookError attr_reader :path def initialize(path) @str = "Log path '#{Paint[path, "red"]}' does not exist!" @path = Pathname.new(path) super(@str, 97) end end end
Version data entries
33 entries across 33 versions & 1 rubygems