MCPcopy Index your code
hub / github.com/python/cpython / _write_file_prefix

Function _write_file_prefix

Lib/zipapp.py:46–50  ·  view source on GitHub ↗

Write a shebang line.

(f, interpreter)

Source from the content-addressed store, hash-verified

44
45
46def _write_file_prefix(f, interpreter):
47 """Write a shebang line."""
48 if interpreter:
49 shebang = b'#!' + interpreter.encode(shebang_encoding) + b'\n'
50 f.write(shebang)
51
52
53def _copy_archive(archive, new_archive, interpreter=None):

Callers 2

_copy_archiveFunction · 0.85
create_archiveFunction · 0.85

Calls 2

encodeMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…