{"id":36563119,"url":"https://github.com/projg2/python-exec","last_synced_at":"2026-01-14T20:44:59.079Z","repository":{"id":44806849,"uuid":"58803365","full_name":"projg2/python-exec","owner":"projg2","description":"Wrapper for multi-implementation install of Python scripts and executables","archived":false,"fork":false,"pushed_at":"2023-03-20T06:06:39.000Z","size":165,"stargazers_count":14,"open_issues_count":4,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-01-12T15:07:48.345Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/projg2.png","metadata":{"files":{"readme":"README","changelog":null,"contributing":null,"funding":null,"license":"COPYING","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-05-14T10:58:06.000Z","updated_at":"2025-03-13T10:34:18.000Z","dependencies_parsed_at":"2024-06-21T14:27:45.547Z","dependency_job_id":"fdd983d1-3d1b-44bc-83ac-bdbdbb5d3d1d","html_url":"https://github.com/projg2/python-exec","commit_stats":null,"previous_names":["mgorny/python-exec"],"tags_count":25,"template":false,"template_full_name":null,"purl":"pkg:github/projg2/python-exec","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projg2%2Fpython-exec","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projg2%2Fpython-exec/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projg2%2Fpython-exec/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projg2%2Fpython-exec/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/projg2","download_url":"https://codeload.github.com/projg2/python-exec/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/projg2%2Fpython-exec/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28434500,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T18:57:19.464Z","status":"ssl_error","status_checked_at":"2026-01-14T18:52:48.501Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-12T06:53:28.131Z","updated_at":"2026-01-14T20:44:59.071Z","avatar_url":"https://github.com/projg2.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"python-exec\n(c) 2012-2018 Michał Górny\nLicensed under the terms of the 2-clause BSD license.\n\n\nIntroduction and usage\n======================\n\npython-exec is a wrapper for Python scripts and executables designed\nin order to facilitate the support for installing multiple Python\nimplementations in parallel.\n\npython-exec provides support for wrapping Python implementations whose\nidentifiers (executable basenames) are passed during configure call\n(obligatory --with-python-impls parameter).\n\nIn order for python-exec to work, wrapped scripts and executables need\nto be installed in subdirectories of scriptroot (defined through\n--with-python-scriptroot parameter, ${prefix}/lib/python-exec\nby default) whose names match appropriate implementations. Afterwards,\npython-exec2 wrapper should be symlinked or copied into an appropriate\nexecutable directory using the name of the wrapped script.\n\nIn other words, to wrap /usr/bin/foo, you would:\n\n1. install the real script into /usr/lib/python-exec/pythonX.Y/foo,\n\n2. symlink /usr/bin/foo -\u003e /usr/lib/python-exec/python-exec2.\n\nAfterwards, whenever the wrapper script is run python-exec will try to\ndetermine the most preferred Python implementation supported by\nthe script and run the appropriate variant. It should be noted that\nthe wrapped script needs to have an appropriate shebang in order to run\nmatching Python interpreter.\n\n\nConfiguration\n=============\n\npython-exec supports two configuration layers: EPYTHON environment\nvariable and a configuration file.\n\nThe EPYTHON environment variable can be used to configure python-exec at\nruntime and/or override local configuration. If it is defined, it\nspecifies the most preferred Python interpreter that should be used to\nrun the script. If the specified interpreter is unsupported by\nthe script, python-exec will fall back to configuration file and/or\ndefault order.\n\nThe configuration file (example in config/python-exec.conf.example)\nneeds to be installed in ${sysconfdir}/python-exec/python-exec.conf. It\nlists preferred Python implementations in preference order. For more\ninformation, please look at the detailed usage guide in the example\nfile.\n\nIf none of the explicitly preferred implementations are supported by\nthe script, python-exec falls back to trying any other implementation\nknown to it (i.e. specified at build-time) that is not explicitly\ndisabled via configuration.\n\n\nRecovery notes\n==============\n\npython-exec2 itself and its build system does not require any version of\nPython being installed. This also means that it can be securely\nreinstalled if it becomes broken and Python scripts stop to work\ncorrectly.\n\nIf the python-exec2 wrapper (in ${python_scriptroot}) becomes damaged\n(e.g. overwritten by insecure use of old version of distutils), you can\nreplace it with python-exec2c wrapper (from ${bindir}). This will break\nuses of 'python /usr/bin/foo' but otherwise render the wrapper\nfunctional.\n\nThe python-exec2c wrapper can be called directly. For example, in order\nto execute the script foo, you can call:\n\n    python-exec2c foo\n\nAll wrapped scripts are installed in ${python_scriptroot} and usable\ndirectly. If everything else fails, you can simply call:\n\n    /usr/lib/python-exec/python3.4/foo\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprojg2%2Fpython-exec","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprojg2%2Fpython-exec","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprojg2%2Fpython-exec/lists"}