Class: Wurfl::Command::Uaproftowurfl
- Inherits:
-
Object
- Object
- Wurfl::Command::Uaproftowurfl
- Defined in:
- lib/wurfl/command/uaproftowurfl.rb
Instance Method Summary collapse
Instance Method Details
#execute ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/wurfl/command/uaproftowurfl.rb', line 5 def execute if ARGV.size == 0 usage end uaprof = Wurfl::UAProfToWURLF.new # Parse all the files and merge them into one UAProf. # Following profs take precedence of previous ones ARGV.each do |file| uaprof.parse_UAProf(file) end # Now output the mapped WURFL to standard out uaprof.output_WURFL end |
#usage ⇒ Object
22 23 24 25 26 |
# File 'lib/wurfl/command/uaproftowurfl.rb', line 22 def usage puts "Usage: wurfltools.rb uaproftowurfl uaprof_files" puts "No files passed to parse." exit 1 end |