Sha256: 56a595682e608996e6e2f4dbcb504f965103214656801cf9f01c3d1b4ffb5ce4

Contents?: true

Size: 601 Bytes

Versions: 2

Compression:

Stored size: 601 Bytes

Contents

# frozen_string_literal: true

require_relative 'tty/cli'
require_relative 'tty/plugins'
require_relative 'tty/version'

module TTY
  GEMSPEC_PATH = ::File.expand_path("#{::File.dirname(__FILE__)}/../tty.gemspec")

  class << self
    def included(base)
      base.send :extend, ClassMethods
    end
  end

  module ClassMethods
    # Return shared plugins instance
    #
    # @return [TTY::Plugins]
    #
    # @api public
    def plugins
      @plugins ||= Plugins.new
    end
  end

  extend ClassMethods
end # TTY

TTY.plugins.load_from(TTY::GEMSPEC_PATH, /tty-(.*)|pastel/)
TTY.plugins.activate

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
tty-0.10.0 lib/tty.rb
tty-0.9.1 lib/tty.rb