6 Copyright (C) 2005, Catalin Marinas <catalin.marinas@gmail.com>
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License version 2 as
10 published by the Free Software Foundation.
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, see http://www.gnu.org/licenses/.
21 if __name__ == '__main__':
22 if sys.version_info[:2] < (3, 5):
23 sys.stderr.write('StGit requires Python >= 3.5\n')
26 if os.environ.get('COVERAGE_PROCESS_START'):
31 if len(sys.argv) < 2 or sys.argv[1].startswith('-'):
34 context = 'stg-' + sys.argv[1]
36 cov = coverage.process_startup()
37 cov.switch_context(context)
39 from stgit.main import main