Class: DZEN::Terminal

Inherits:
Base
  • Object
show all
Defined in:
lib/dzen/base.rb

Overview

Simple Terminal-aware output. May be used within a simple “watch” command Maybe integration in screen is possible

Constant Summary collapse

Colors =
{
  :black => 30,
  :red => 31,
  :green => 32,
  :yellow => 33,
  :blue => 34,
  :magenta => 35,
  :cyan => 36,
  :white => 37
}
Config =
{
  :delimiter => " | ",
  :start => "\r",
  :interval => 3,
  :output => $stdout,
  :output_method => :print,
  :color => {
    :start => proc{|c|
      Colors[c] && "\e[#{Colors[c]}m"
    },
    :end => proc{|c| Colors[c] && "\e[0m" }
  }
}

Instance Attribute Summary

Attributes inherited from Base

#config

Method Summary

Methods inherited from Base

#add_before_run, #add_handler, #configure, #initialize, #order=, #run!, #sort_apps!

Constructor Details

This class inherits a constructor from DZEN::Base