Skip to content

Add Command::env_clear method #74

Description

@jsha

std::process:Command has an env_clear method to clear all environment variables before forking a process. As far as I can tell, it's not possible to call this on rustwide::cmd::Command. It would be nice to add it. In particular, docs.rs uses rustwide::cmd::Command to run cargo fetch in a non-containerized process; clearing the environment would be one simple way to reduce the possibility of accidentally propagating host configuration. See rust-lang/docs.rs#1881 for an example.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions