Sha256: 5ee4f4478d16fee56ec376c88a96e745ee1205c5f80216fbed571d9cf9126f4a

Contents?: true

Size: 368 Bytes

Versions: 6

Compression:

Stored size: 368 Bytes

Contents

module Hanzo
  module Heroku
    class << self

      def available_labs
        Hanzo.run("heroku labs").each_line.to_a.inject([]) do |memo, line|
          if line = /^\[\s\]\s+(?<name>\w+)\s+(?<description>.+)$/.match(line)
            memo << [line[:name], line[:description]]
          else
            memo
          end
        end
      end

    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
hanzo-0.4.2 lib/hanzo/heroku.rb
hanzo-0.4.1 lib/hanzo/heroku.rb
hanzo-0.4 lib/hanzo/heroku.rb
hanzo-0.3.1 lib/hanzo/heroku.rb
hanzo-0.3 lib/hanzo/heroku.rb
hanzo-0.2.3 lib/hanzo/heroku.rb