Skip to content

What language is flake.nix written in? #4945

Description

@dasJ

This issue may sound silly but it's actually not clear to me what language they are written in.
The syntax and file ending both look like Nix but the manual doesn't apply most of the time.
The manual makes it seem like this should work:

{
  description = "Testflake";
  outputs = import ./outputs.nix;
}

but running that results in

error: expected a function but got a thunk at /nix/store/lm4pyqnkbiwvp2kxjd64nqb2xkdxmbfx-source/flake.nix:4:3

So what language are flake.nix files written in (is there any specification or documentation) and why is that language not Nix?

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions