Class: Nanoc::Extra::Validators::W3C Deprecated
- Inherits:
-
Object
- Object
- Nanoc::Extra::Validators::W3C
- Defined in:
- lib/nanoc/extra/validators/w3c.rb
Overview
Deprecated.
Use the Checking API or the check
command instead
Instance Method Summary (collapse)
-
- (W3C) initialize(dir, types)
constructor
A new instance of W3C.
-
- (Object) run
Constructor Details
- (W3C) initialize(dir, types)
Returns a new instance of W3C
8 9 10 11 |
# File 'lib/nanoc/extra/validators/w3c.rb', line 8 def initialize(dir, types) @dir = dir @types = types end |
Instance Method Details
- (Object) run
13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/nanoc/extra/validators/w3c.rb', line 13 def run args = [] types = @types.dup args << 'html' if types.delete(:html) args << 'css' if types.delete(:css) unless types.empty? raise Nanoc::Errors::GenericTrivial, "unknown type(s) specified: #{types.join(', ')}" end Nanoc::CLI.run([ 'check', args ].flatten) end |