Class: Liquidscript::CLI
- Inherits:
-
Thor
- Object
- Thor
- Liquidscript::CLI
- Defined in:
- lib/liquidscript/cli.rb
Instance Method Summary collapse
Instance Method Details
#compile(*files) ⇒ Object
21 22 23 24 25 26 27 |
# File 'lib/liquidscript/cli.rb', line 21 def compile(*files) files.each do |file| puts "COMPILING: #{file}" perform_compiliation(file, [:out] || file.gsub('.liq', '.js')) end end |
#syntax(*files) ⇒ Object
35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/liquidscript/cli.rb', line 35 def syntax(*files) errored = files.select do |file| print "CHECKING: #{file} " !preform_syntax_check(file) end if errored.size > 0 puts "#{errored.join(', ')} did not pass the syntax check" exit 1 end end |