From fcdf4a0f355fd95c591738aa1ae887518f1f97f3 Mon Sep 17 00:00:00 2001 From: David Wilson Date: Wed, 31 Oct 2018 16:18:04 +0000 Subject: [PATCH] Import missing stub-sudo.py. --- tests/data/stubs/stub-sudo.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100755 tests/data/stubs/stub-sudo.py diff --git a/tests/data/stubs/stub-sudo.py b/tests/data/stubs/stub-sudo.py new file mode 100755 index 00000000..ff88cd8e --- /dev/null +++ b/tests/data/stubs/stub-sudo.py @@ -0,0 +1,9 @@ +#!/usr/bin/env python + +import json +import os +import sys + +os.environ['ORIGINAL_ARGV'] = json.dumps(sys.argv) +os.environ['THIS_IS_STUB_SUDO'] = '1' +os.execv(sys.executable, sys.argv[sys.argv.index('--') + 1:])