Skip to content

Let aliases in .cargo/config.toml specify environment variables #12477

Open
@not-my-profile

Description

@not-my-profile

Problem

The [alias] table in .cargo/config.toml lets you define command aliases but it doesn't let you specify environment variables for these commands.

Proposed Solution

Support environment variables to be specified as follows:

[alias]
docsrs = {command="doc", env={RUSTDOCFLAGS="--cfg docsrs"}}

Notes

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-aliasesArea: command aliasesC-feature-requestCategory: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`S-needs-designStatus: Needs someone to work further on the design for the feature or fix. NOT YET accepted.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions