Sha256: dd49e1cc7fe388b728e68a7785eba20b629a0eb4d38f8af684fb57f8b56a7415

Contents?: true

Size: 599 Bytes

Versions: 11

Compression:

Stored size: 599 Bytes

Contents

# frozen_string_literal: true

module SublimeTextKit
  module Snippets
    module Printers
      # Prints snippets in ASCII Doc format.
      class ASCIIDoc
        def initialize collector: Collector.new, container: Container
          @collector = collector
          @container = container
        end

        def call
          collector.call.each do |snippet|
            logger.info "* #{snippet.description} - `#{snippet.trigger}`"
          end
        end

        private

        attr_reader :collector, :container

        def logger = container[__method__]
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
sublime_text_kit-12.3.2 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-12.3.1 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-12.3.0 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-12.2.0 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-12.1.0 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-12.0.1 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-12.0.0 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-11.0.3 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-11.0.2 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-11.0.1 lib/sublime_text_kit/snippets/printers/ascii_doc.rb
sublime_text_kit-11.0.0 lib/sublime_text_kit/snippets/printers/ascii_doc.rb