Skip to content

/etc/nix-darwin/flake.nix vs user's home directory - for version control (i.e. git)? #1750

@victorhooi

Description

@victorhooi

I believe when I last asked, the recommended practice was to have the configuration in /etc/nix-darwin/flake.nix.

(Earlier discussion at #1360).

And the default steps in the nix-darwin README achieve this.

However, if I want to version control my flake.nix directory - what's the "correct" way to do that?

Are we meant to create a git repo in /etc/nix-darwin, or is that an anti-pattern?

Or should we be doing it in our home directory somewhere (~/.config/nix-darwin? ~/dotfiles?), and doing some weird symlink magic? Or is that likely to break things, like when I tried earlier?

And if I'm also using home-manager, we still keep everything in /etc/nix-darwin/flake.nix, right?

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