Return to Snippet

Revision: 14023
at May 15, 2009 13:00 by iloveitaly


Initial Code
#!/usr/bin/env ruby -wKU
 
scope = STDIN.read
scope.gsub!(/< \/?style.*?>/, '')
 
open('|curl -sF file=@-\;type=text/css -F lang=en http://jigsaw.w3.org/css-validator/validator', 'r+') do |io|
io < < scope
io.close_write
 
while io.gets
$_.gsub!(/<\/title>/, '\&')
print $_
end
end

Initial URL

                                

Initial Description

                                

Initial Title
TextMate Local CSS Validation

Initial Tags
css, textmate

Initial Language
Ruby