Sha256: 710a23af371f0486b6195d4420b6641adaa076864347a68f85ce747940aa08a4

Contents?: true

Size: 1.06 KB

Versions: 37

Compression:

Stored size: 1.06 KB

Contents

# -*- coding: utf-8 -*-
#
# Copyright 2013 whiteleaf. All rights reserved.
#

require "optparse"
require_relative "commandbase"
Dir.glob(File.expand_path(File.join(File.dirname(__FILE__), "command", "*.rb"))) do |path|
  require path
end

module Command
  #
  # コマンド一覧を取得
  #
  def self.get_list
    COMMAND_LIST
  end

  COMMAND_LIST = {
    "download" => Download.new,
    "update" => Update.new,
    "list" => List.new,
    "convert" => Convert.new,
    "diff" => Diff.new,
    "setting" => Setting.new,
    "alias" => Alias.new,
    "inspect"=> Inspect.new,
    "send" => Send.new,
    "folder" => Folder.new,
    "browser" => Browser.new,
    "remove" => Remove.new,
    "freeze" => Freeze.new,
    "help" => Help.new,
    "version" => Version.new,
    #"new" => New.new,
    #"interactive" => Interactive.new,
    "init" => Init.new
  }

  # ショートカット定義
  # COMMAND_LIST の上から順に優先度が高い
  Shortcuts = Hash[*get_list.keys.reverse.map { |s|
    [s[0], s, s[0..1], s]
  }.flatten]
end

Version data entries

37 entries across 37 versions & 1 rubygems

Version Path
narou-1.5.1 lib/command.rb
narou-1.5.0.2 lib/command.rb
narou-1.5.0.1 lib/command.rb
narou-1.5.0 lib/command.rb
narou-1.4.6 lib/command.rb
narou-1.4.5 lib/command.rb
narou-1.4.4 lib/command.rb
narou-1.4.3 lib/command.rb
narou-1.4.2.rc2 lib/command.rb
narou-1.4.2.rc1 lib/command.rb
narou-1.4.1.1 lib/command.rb
narou-1.4.1 lib/command.rb
narou-1.4.0 lib/command.rb
narou-1.3.5.1 lib/command.rb
narou-1.3.5 lib/command.rb
narou-1.3.4 lib/command.rb
narou-1.3.3 lib/command.rb
narou-1.3.2 lib/command.rb
narou-1.3.1 lib/command.rb
narou-1.3.0.1 lib/command.rb