Skip to content

Commit

Permalink
Don't print tracebacks if completer is interrupted
Browse files Browse the repository at this point in the history
Fixes #628.
  • Loading branch information
jamesls committed Feb 5, 2014
1 parent 805a649 commit 83548aa
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion bin/aws_completer
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,9 @@ if __name__ == '__main__':
# bash exports COMP_LINE and COMP_POINT, tcsh COMMAND_LINE only
cline = os.environ.get('COMP_LINE') or os.environ.get('COMMAND_LINE') or ''
cpoint = int(os.environ.get('COMP_POINT') or len(cline))
awscli.completer.complete(cline, cpoint)
try:
awscli.completer.complete(cline, cpoint)
except KeyboardInterrupt:
# If the user hits Ctrl+C, we don't want to print
# a traceback to the user.
pass

0 comments on commit 83548aa

Please sign in to comment.