Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion stgit/commands/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ def get_commands(allow_cached=True):
def py_commands(commands, f):
f.write('from __future__ import unicode_literals\n\n')
f.write('command_list = {\n')
for name, (mod, kind, help) in commands.items():
for name, (mod, kind, help) in sorted(commands.items()):
f.write(' %r: (\n' % name)
f.write(' %r,\n' % mod)
f.write(' %r,\n' % kind)
Expand Down
4 changes: 2 additions & 2 deletions stgit/completion/bash.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def command(self, var):
cmd += ['-A', act]
words = self.words(var)
if words:
cmd += ['-W', '"%s"' % ' '.join(words)]
cmd += ['-W', '"%s"' % ' '.join(sorted(words))]
cmd += ['--', '"%s"' % var]
return ' '.join(cmd)

Expand Down Expand Up @@ -76,7 +76,7 @@ def words(self, var):
for e_word in e.words(var):
if e_word not in words:
words.append(e_word)
return ['$(_patch_range "%s" "%s")' % (' '.join(words), var)]
return ['$(_patch_range "%s" "%s")' % (' '.join(sorted(words)), var)]


def compjoin(compgens):
Expand Down