class SnippetCli::Commands::Info

Public Class Methods

new(docs, options) click to toggle source
# File lib/snippet_cli/commands/info.rb, line 10
def initialize(docs, options)
  @docs = docs
  @options = options
end

Public Instance Methods

execute(input: $stdin, output: $stdout) click to toggle source
# File lib/snippet_cli/commands/info.rb, line 15
def execute(input: $stdin, output: $stdout)
        def show_banner()
  box = TTY::Box::frame(width:67, height:11, border: :thick, align: :left) do 
  "
  #####   #     # ### ######  ######  ####### ####### 
  #     # ##    #  #  #     # #     # #          #    
  #       # #   #  #  #     # #     # #          #    
   #####  #  #  #  #  ######  ######  #####      #    
        # #   # #  #  #       #       #          #    
  #     # #    ##  #  #       #       #          #    
   #####  #     # ### #       #       #######    #    CLI                                                                
  "
  end
  puts box
end
  puts show_banner()
  parsed_markdown=TTY::Markdown.parse_file('./lib/info.md')
  output.puts parsed_markdown
end
show_banner() click to toggle source
# File lib/snippet_cli/commands/info.rb, line 16
        def show_banner()
  box = TTY::Box::frame(width:67, height:11, border: :thick, align: :left) do 
  "
  #####   #     # ### ######  ######  ####### ####### 
  #     # ##    #  #  #     # #     # #          #    
  #       # #   #  #  #     # #     # #          #    
   #####  #  #  #  #  ######  ######  #####      #    
        # #   # #  #  #       #       #          #    
  #     # #    ##  #  #       #       #          #    
   #####  #     # ### #       #       #######    #    CLI                                                                
  "
  end
  puts box
end