Sha256: 6590096e4df535e32d8c9062024e5dc553f02749f25d8e13d32060ee7343aa98

Contents?: true

Size: 603 Bytes

Versions: 1

Compression:

Stored size: 603 Bytes

Contents

module Troo
  module Commands
    module Status
      class Board < Resource
        private

        def success
          '  Boards: ' + plural('board') + " found.\n" +
          "          #{resource_title}"
        end

        def error
          if count > 0
            '  Boards: ' + Esc.red + 'No default board set.' + Esc.reset
          else
            "  Boards: No boards found.\n"
          end
        end

        def count
          @count ||= Troo::Board.count
        end

        def resource
          @resource ||= Retrieval::Board.default
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
troo-0.0.8 lib/troo/commands/status/board.rb