Sha256: 62765a64ba35bfdb5ade81dcb4a0f2e26c577670f69c6c520bd15d5b53381b7f
Contents?: true
Size: 387 Bytes
Versions: 1
Compression:
Stored size: 387 Bytes
Contents
require "ja_prefecture/cli/constant" require "thor" module JaPrefecture module CLI class Command < Thor desc "list", "Prefectures in Japan" def list PREFECTURE_MAP.map do |k, v| suffix = IRREGULAR_SUFFIX_MAP.has_key?(k.to_sym) ? IRREGULAR_SUFFIX_MAP[k.to_sym] : "県" puts v[:name].to_s + suffix.to_s end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ja_prefecture-cli-0.1.0 | lib/ja_prefecture/cli/command.rb |