lib/airplayer/app.rb in airplayer-0.0.1 vs lib/airplayer/app.rb in airplayer-0.0.2
- old
+ new
@@ -1,11 +1,12 @@
require 'thor'
module AirPlayer
class App < Thor
- desc 'play [URI|FILE]', 'Play video(URI or local video file path)'
+ desc 'play <URI|FILE> [-r|--repeat]', 'Play video(URI or local video file path)'
+ method_option :repeat, :aliases => '-r', :desc => 'Repeat play'
def play(uri)
- Player.new.play(uri)
+ Player.play(uri, options.repeat?)
end
map '--version' => :version
desc 'version, --version', 'Display version'
def version