Why not just use the Sass APIs directly? Check out the source for sass-convert to see how. It's all pretty straightforward.
On Tue, Aug 3, 2010 at 4:25 PM, Charles Roper <reac...@charlesroper.co.uk>wrote: > Hi, > > Is it possible to pass a string to SassConvert? I can do something like > this: > > require 'rubygems' > require 'haml/exec' > STDIN = ENV['TM_SELECTED_TEXT'] > opts = Haml::Exec::SassConvert.new(%w{--from sass --to scss --stdin}) > opts.parse! > > But that gives me a warning about STDIN already being defined. Is > there a more elegant way to approach this? > > TM_SELECTED_TEXT contains this: "body\n font-family: > $base_font_family\n color: $cat_shadow" > > Cheers, > Charles > > -- > You received this message because you are subscribed to the Google Groups > "Haml" group. > To post to this group, send email to h...@googlegroups.com. > To unsubscribe from this group, send email to > haml+unsubscr...@googlegroups.com <haml%2bunsubscr...@googlegroups.com>. > For more options, visit this group at > http://groups.google.com/group/haml?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Haml" group. To post to this group, send email to h...@googlegroups.com. To unsubscribe from this group, send email to haml+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/haml?hl=en.