Class: Iterm2mintty

Inherits:
Object
  • Object
show all
Defined in:
lib/iterm2mintty.rb,
lib/iterm2mintty/version.rb

Defined Under Namespace

Modules: Colorable, MinttyColor Classes: ANSIColor, BGColor, Color, CursorColor, FGColor, Mintty

Constant Summary collapse

VERSION =
"0.0.2"

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(pathname:) ⇒ Iterm2mintty

Returns a new instance of Iterm2mintty.



8
9
10
# File 'lib/iterm2mintty.rb', line 8

def initialize(pathname:)
  @pathname = pathname
end

Instance Attribute Details

#ansi_colorsObject (readonly)

Returns the value of attribute ansi_colors.



6
7
8
# File 'lib/iterm2mintty.rb', line 6

def ansi_colors
  @ansi_colors
end

#pathnameObject (readonly)

Returns the value of attribute pathname.



6
7
8
# File 'lib/iterm2mintty.rb', line 6

def pathname
  @pathname
end

Instance Method Details

#convertObject



12
13
14
15
16
# File 'lib/iterm2mintty.rb', line 12

def convert
  ansi_colors.map do |color|
    color.to_mintty + "\n"
  end.join
end

#parsed_themeObject



40
41
42
# File 'lib/iterm2mintty.rb', line 40

def parsed_theme
  @parsed_theme ||= Plist.parse_xml(pathname)
end