def build_usage(self, without_name=False):
        '''Build the usage of this command.

        :param without_name: Make it return an usage without the function name.
        :type without_name: bool
        :rtype: str
        '''

        # build reverse alias map
        alias_arg_rmap = {}
        for alias, arg_name in self.alias_arg_map.items():
            aliases = alias_arg_rmap.setdefault(arg_name, [])
            aliases.append(alias)

        usage = []

        # build the arguments which have default value
        if self.arg_defaults:
            for arg_name in self.arg_names[-len(self.arg_defaults):]:

                pieces = []
                for name in alias_arg_rmap.get(arg_name, [])+[arg_name]:

                    is_long_opt = len(name) > 1
                    pieces.append('%s%s' % ('-' * (1+is_long_opt), name.replace('_', '-')))

                    meta = self.arg_meta_map.get(name)
                    if meta is None:
                        # autometa
                        default = self.arg_default_map[self.dealias(name)]
                        if isinstance(default, bool):
                            continue
                        elif default is None:
                            meta = '<value>'
                        else:
                            meta = '{!r}'.format(default)

                    if is_long_opt:
                        pieces[-1] += '='+meta
                    else:
                        pieces[-1] += ' '+meta

                usage.append('[%s]' % ' | '.join(pieces))

        if self.keyarg_name:
            usage.append('[--<key>=<value>...]')

        # build the arguments which don't have default value
        usage.extend('<%s>' % name.replace('_', '-') for name in self.arg_names[:-len(self.arg_defaults) or None])

        if self.vararg_name:
            usage.append('[<%s>...]' % self.vararg_name.replace('_', '-'))

        if without_name:
            return '%s' % ' '.join(usage)
        else:
            return ((self.name or self.func.__name__).replace('_', '-'), ' '.join(usage)) % '%s %s'
dataset/ETHPy150Open moskytw/clime/clime/core.py/Command.build_usage/swapped operands of `%`