diff --git a/beets/ui/__init__.py b/beets/ui/__init__.py index 35c1b1957..2acff947c 100644 --- a/beets/ui/__init__.py +++ b/beets/ui/__init__.py @@ -786,14 +786,6 @@ class CommonOptionsParser(optparse.OptionParser, object): self.add_path_option() self.add_format_option() - def add_help_text(self, text): - """Add a custom help text below the usage line to give extra hints - """ - if self._added_help is False: - self.usage = self.usage + "\n" - self._added_help = True - self.usage = self.usage + "\n" - self.usage = self.usage + text # Subcommand parsing infrastructure. # @@ -803,7 +795,6 @@ class CommonOptionsParser(optparse.OptionParser, object): # There you will also find a better description of the code and a more # succinct example program. - class Subcommand(object): """A subcommand of a root command-line application that may be invoked by a SubcommandOptionParser. diff --git a/beets/ui/commands.py b/beets/ui/commands.py index e87a1b18d..37b7ddc0a 100644 --- a/beets/ui/commands.py +++ b/beets/ui/commands.py @@ -973,10 +973,8 @@ def list_func(lib, opts, args): list_cmd = ui.Subcommand('list', help='query the library', aliases=('ls',)) -list_cmd.parser.add_help_text('query the library') -list_cmd.parser.add_help_text( - 'Example usage: %prog -f \'$album: $title\' artist:beatles' -) +list_cmd.parser.usage += "\n" \ + 'Example: %prog -af \'$album: $title\' artist:beatles' list_cmd.parser.add_all_common_options() list_cmd.func = list_func default_commands.append(list_cmd)