Sha256: 9933d6dd5f99cb731d318863be9df53eec42b8bb8e4f3ed2e433964930b027b6
Contents?: true
Size: 1.25 KB
Versions: 3
Compression:
Stored size: 1.25 KB
Contents
module Spackle class Configuration # The command to invoke when Spackle finds errors. It will receive # a single argument, being the path to the Spackle errors file. # If left unspecified, no command is invoked. attr_accessor :callback_command # Where to store the Spackle error files. If unspecified, Spackle will # default to /tmp attr_accessor :tempdir # Which ErrorFormatter class to use when formatting errors. Specified # as a symbol or string matching a class in spackle/error_formatters. # i.e. config.error_formatter = :vim_quickfix attr_accessor :error_formatter # Filename to use when writing the formatted Spackle results. If # unspecified, defaults to a filename based on the name of your # project's root directory, or "default.spackle" it can't figure out # where your root directory is attr_accessor :spackle_file # Configure Spackle with defaults. Currently only accepts :vim as an # argument. def set_defaults_for(mode) case mode.to_sym when :vim self.callback_command = "spackle-vim-load-quickfix" self.error_formatter = :vim_quickfix else raise ArgumentError.new("unknown Spackle mode: '#{mode}'") end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
spackle-0.0.3 | lib/spackle/configuration.rb |
spackle-0.0.2 | lib/spackle/configuration.rb |
spackle-0.0.1 | lib/spackle/configuration.rb |