Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use actual pyp interpreter in shebang by default #29

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyp.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ def __init__(self) -> None:
# Modules from which automatic imports work without qualification, ordered by AST encounter
self.wildcard_imports: List[str] = []

self.shebang: str = "#!/usr/bin/env python3"
self.shebang: str = f"#!{sys.interpreter}"
Bobronium marked this conversation as resolved.
Show resolved Hide resolved
if config_contents.startswith("#!"):
self.shebang = "\n".join(
itertools.takewhile(lambda l: l.startswith("#"), config_contents.splitlines())
Expand Down