Sha256: 811688820cbeee11e4cea7d828d8630037613a8abf33a01f33021a369830157d
Contents?: true
Size: 1.35 KB
Versions: 3
Compression:
Stored size: 1.35 KB
Contents
# lib/aia.rb def tramp_require(what, &block) loaded, require_result = false, nil begin require_result = require what loaded = true rescue Exception => ex # Do nothing end yield if loaded and block_given? require_result end tramp_require('debug_me') { include DebugMe } require 'hashie' require 'os' require 'pathname' require 'reline' require 'shellwords' require 'tempfile' # SMELL: is this still being used? require 'tty-spinner' unless TTY::Spinner.new.respond_to?(:log) # Allows messages to be sent to the console while # the spinner is still spinning. require_relative './core_ext/tty-spinner_log' end require 'prompt_manager' require 'prompt_manager/storage/file_system_adapter' require_relative "aia/version" require_relative "aia/clause" require_relative "aia/main" require_relative "core_ext/string_wrap" module AIA class << self attr_accessor :config def run(args=ARGV) args = args.split(' ') if args.is_a?(String) # TODO: Currently this is a one and done architecture. # If the args contain an "-i" or and "--interactive" # flag could this turn into some kind of # conversation REPL? AIA::Main.new(args).call end def speak(what) return unless AIA.config.speak? system "say #{Shellwords.escape(what)}" if OS.osx? end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
aia-0.5.13 | lib/aia.rb |
aia-0.5.12 | lib/aia.rb |
aia-0.5.11 | lib/aia.rb |