processor/command/alias.rb in rb8-trepanning-0.1.3 vs processor/command/alias.rb in rb8-trepanning-0.1.4
- old
+ new
@@ -1,16 +1,27 @@
# Copyright (C) 2010, 2011 Rocky Bernstein <rockyb@rubyforge.net>
require 'rubygems'; require 'require_relative'
-require_relative 'base/cmd'
+require_relative '../command'
class Trepan::Command::AliasCommand < Trepan::Command
unless defined?(HELP)
NAME = File.basename(__FILE__, '.rb')
HELP = <<-HELP
#{NAME} ALIAS COMMAND
-Add an alias for a COMMAND
+Add alias ALIAS for a debugger command COMMAND.
+
+Add an alias when you want to use a command abbreviation for a command
+that would otherwise be ambigous. For example, by default we make 's'
+be an alias of 'step' to force it to be used. Without the alias, "s"
+might be "step", "show", or "set" among others
+
+Example:
+
+alias cat list # "cat rubyfile.rb" is the same as "list rubyfile.rb"
+alias s step # "s" is now an alias for "step".
+ # The above examples done by default.
See also 'unalias' and 'show #{NAME}'.
HELP
CATEGORY = 'support'