class Fission::Command
def command_name(klass=self)
# => 'snapshot list'
Fission::Command::SnapshotList.new.command_name
#xamples:
This should only be called against descendants of this class.
Internal: Helper method to determine the command name of command class.
def command_name(klass=self) klass.class.name.split('::')[2]. gsub(/([a-z\d])([A-Z])/,'\1_\2'). gsub('_', ' ').downcase end