Sha256: f3bdc119b9dd27bed5553489b08bd915b0b01885eaa8b6a44c887894e4303a42
Contents?: true
Size: 562 Bytes
Versions: 1
Compression:
Stored size: 562 Bytes
Contents
# encoding: utf-8 module GithubCLI # Responsible for display and size detection. class Terminal DEFAULT_WIDTH = 120 DEFAULT_HEIGHT = 40 class << self attr_accessor :size def print_commands(pattern=nil) GithubCLI.ui.info 'Commands:' Command.all.each do |cmd| print_command cmd if pattern && cmd.namespace =~ pattern end end def print_command(cmd, usage_text='usage') GithubCLI.ui.info " ghc #{cmd.namespace} #{cmd.usage}" end end end # Terminal end # GithubCLI
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
github_cli-0.1.0 | lib/github_cli/terminal.rb |