lib/gzr/commands/subcommandbase.rb in gazer-0.3.7 vs lib/gzr/commands/subcommandbase.rb in gazer-0.3.8

- old
+ new

@@ -1,8 +1,8 @@ # The MIT License (MIT) -# Copyright (c) 2018 Mike DeAngelo Looker Data Sciences, Inc. +# Copyright (c) 2023 Mike DeAngelo Google, Inc. # Permission is hereby granted, free of charge, to any person obtaining a copy of # this software and associated documentation files (the "Software"), to deal in # the Software without restriction, including without limitation the rights to # use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of @@ -32,10 +32,10 @@ def self.banner(command, namespace = nil, subcommand = false) "#{basename} #{subcommand_prefix} #{command.usage}" end def self.subcommand_prefix - self.name.gsub(%r{.*::}, '').gsub(%r{^[A-Z]}) { |match| match[0].downcase }.gsub(%r{[A-Z]}) { |match| "-#{match[0].downcase}" } + self.namespace end end end end