blob: 68a4b52727fc8e144cd773a387d432ca1ff9df28 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
# frozen_string_literal: true
#
# irb/command.rb - irb command
# by Keiju ISHITSUKA([email protected])
#
require_relative "command/base"
module IRB # :nodoc:
module Command
@commands = {}
class << self
attr_reader :commands
# Registers a command with the given name.
# Aliasing is intentionally not supported at the moment.
def register(name, command_class)
@commands[name.to_sym] = [command_class, []]
end
end
end
end
|