Skip to content

Commit

Permalink
bin/merge-driver-ekeyword: mangle exit code correctly
Browse files Browse the repository at this point in the history
Fixes: 263e3d6
Signed-off-by: Sam James <[email protected]>
  • Loading branch information
thesamesam committed Aug 29, 2023
1 parent 263e3d6 commit fb45df3
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions bin/merge-driver-ekeyword
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/usr/bin/python
#!/usr/bin/python3
#
# Copyright 2020 Gentoo Authors
# Copyright 2020-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2 or later

"""
Expand Down Expand Up @@ -127,8 +127,10 @@ def main(argv: Sequence[str]) -> int:
sys.exit(result)
else:
result = os.system(f"git merge-file -L HEAD -L base -L ours {A} {O} {B}")
result = os.waitstatus_to_exitcode(result)
if result < 0 or result >= 128:
sys.exit(-1)
sys.exit(result)


if __name__ == "__main__":
main(sys.argv)

0 comments on commit fb45df3

Please sign in to comment.