Skip to content

Can't set environment variables in shellFor any more #2401

Closed
@michaelpj

Description

@michaelpj

Describe the bug

Normally in nix derivations extra attributes get set as environment variables, so you could do e.g.

shellFor {
   FOO = "bar";
}

and it would set FOO in the shell. Since some point recently this started saying:

error: The option `shell.FOO' does not exist. Definition values:                                                                                                                                                                              
- In `<unknown-file>': 1   

Expected behavior

The extra attribute should just be passed through to the final derivation. Unless this is intentional.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions