From 611a4443d7b439e0896b119bd7c15fa93a05ec7e Mon Sep 17 00:00:00 2001 From: Squeaky Date: Sat, 3 Aug 2019 18:46:28 +0200 Subject: [PATCH] add sys.exit(main()) to file_contents_sorter.py --- pre_commit_hooks/file_contents_sorter.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pre_commit_hooks/file_contents_sorter.py b/pre_commit_hooks/file_contents_sorter.py index 6f13c98..1598d2d 100644 --- a/pre_commit_hooks/file_contents_sorter.py +++ b/pre_commit_hooks/file_contents_sorter.py @@ -12,6 +12,7 @@ conflicts and keep the file nicely ordered. from __future__ import print_function import argparse +import sys from typing import IO from typing import Optional from typing import Sequence @@ -53,3 +54,7 @@ def main(argv=None): # type: (Optional[Sequence[str]]) -> int retv |= ret_for_file return retv + + +if __name__ == '__main__': + sys.exit(main())