From e202bd2c202ce5d89f62c034d0225300f7a86808 Mon Sep 17 00:00:00 2001 From: Dmitriy Pleshevskiy Date: Tue, 5 Apr 2022 10:03:33 +0300 Subject: [PATCH] feat(nix/home): add initial config --- .gitignore | 6 ++++++ nix/home.nix | 24 ++++++++++++++++++++++++ nix/secrets.example.nix | 4 ++++ 3 files changed, 34 insertions(+) create mode 100644 nix/home.nix create mode 100644 nix/secrets.example.nix diff --git a/.gitignore b/.gitignore index b4654bd..6869b77 100644 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,12 @@ !/.gitignore +!/nix +/nix/* +!/nix/home.nix +!/nix/*.example.nix + + !/programs /programs/nvim/* diff --git a/nix/home.nix b/nix/home.nix new file mode 100644 index 0000000..fccdf3e --- /dev/null +++ b/nix/home.nix @@ -0,0 +1,24 @@ +{ config, pkgs, ... }: + +let + secrets = import ./secrets.nix; +in +{ + # Home Manager needs a bit of information about you and the + # paths it should manage. + home.username = secrets.username; + home.homeDirectory = secrets.homeDir; + + # This value determines the Home Manager release that your + # configuration is compatible with. This helps avoid breakage + # when a new Home Manager release introduces backwards + # incompatible changes. + # + # You can update Home Manager without changing this value. See + # the Home Manager release notes for a list of state version + # changes in each release. + home.stateVersion = "21.11"; + + # Let Home Manager install and manage itself. + programs.home-manager.enable = true; +} diff --git a/nix/secrets.example.nix b/nix/secrets.example.nix new file mode 100644 index 0000000..eb4f81f --- /dev/null +++ b/nix/secrets.example.nix @@ -0,0 +1,4 @@ +{ + username = "Bob"; + homeDir = "/home/bob"; +}