Provide an escape hatch for ensurepip to control the generated scripts

Closes #1294