Skip to content

Add os.source() or similar functionality #138033

@amantham20

Description

@amantham20

Feature or enhancement

Proposal:

It would be useful if the Python os module supported a function similar to the Unix source command, allowing a script to load environment variables or execute shell configuration from a file directly into the current process.

os.source(".file")

Has this already been discussed elsewhere?

No response given

Links to previous discussion of this feature:

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-featureA feature request or enhancement

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions