# -*- coding: utf-8 -*- require 'optparse' module Kindai class CLI BANNER = < m[1].to_i, :height => m[2].to_i, :x => m[3].to_i, :y => m[4].to_i} } opt.on('--debug', 'enable debug mode') {|v| Kindai::Util.debug_mode! } opt.parse!(arguments) } if arguments.empty? stdout.puts parser.help exit 1 end arguments.each{|file| Kindai::Util.logger.info "publish #{file}" publisher = Kindai::Publisher.new_from_path file publisher.empty('trim') publisher.empty('*zip') if config[:trimming] publisher.trim(config[:trimming]) end publisher.publish_auto } end end end