aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cask/lib/hbc/cli/--version.rb
blob: 1833c51c6794307936b313aead89c2139bcfab8d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
module Hbc
  class CLI
    class Version < AbstractCommand
      def self.command_name
        "--#{super}"
      end

      def initialize(*)
        super
        return if args.empty?
        raise ArgumentError, "#{self.class.command_name} does not take arguments."
      end

      def run
        puts Hbc.full_version
      end

      def self.help
        "displays the Homebrew-Cask version"
      end
    end
  end
end