Sha256: c0691632dfae70590bff31305faa4dc5479c0f11d6fbb8aa6e05c222cb9ab199

Contents?: true

Size: 499 Bytes

Versions: 6

Compression:

Stored size: 499 Bytes

Contents

module LogCabin
  module Modules
    ##
    # Pull state from a homebrew cask file
    module HomebrewCask
      def load!
        fail('No name specified') unless @name
        cask_file = "Casks/#{@name}.rb"
        version_regex = /^\s+version ['"](.+)['"]$/
        Prospectus::State.from_block(@option, @state) do
          grep
          file cask_file
          regex version_regex
        end
      end

      private

      def name(value)
        @name = value
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
prospectus-0.0.12 lib/prospectus/modules/homebrew_cask.rb
prospectus-0.0.11 lib/prospectus/modules/homebrew_cask.rb
prospectus-0.0.10 lib/prospectus/modules/homebrew_cask.rb
prospectus-0.0.9 lib/prospectus/modules/homebrew_cask.rb
prospectus-0.0.8 lib/prospectus/modules/homebrew_cask.rb
prospectus-0.0.6 lib/prospectus/modules/homebrew_cask.rb