diff options
author | Katharina Fey <kookie@spacekookie.de> | 2019-10-05 22:42:42 +0000 |
---|---|---|
committer | Katharina Fey <kookie@spacekookie.de> | 2019-10-05 22:44:50 +0000 |
commit | 73d865b1dae7585d0eff167271dabe77c9d0b8e6 (patch) | |
tree | 337324fab29014f3d60a8bff4979e397fb556d88 /home-manager/tests/default.nix | |
parent | 670a2de0037acadb83433165344710dd3ac03adf (diff) | |
parent | e14d8e29606feddb29d7c27ea62dd514ef80f1e4 (diff) |
Replacing nixcfg with libkookierebuild
Generally, nixcfg grew out of a dotfiles repository, that happened to
also have some scripts in it. As more and more of the configuration
was replaced with nix specifics (home-manager, etc...), so did nixcfg
change over time (previously "stuff").
As part of this, kookiepkgs was introduced along-side nixcfg, to make
it easier to add custom things to nixpkgs-based systems
(NixOS). Additionally, the core system configuration was handled via
private infrastructure repositories, each specific to the machine in
question.
The problem with this approach is a lot of redundancy when building
non-userspace (read home-manager) systems and a lot of chaos with
having to cherry-pick commits from different branches to work with
nixpkgs trees in development.
Ultimately, keeping both new package definitions, patches and
configuration for the root system and userspace (home-manager) in the
same repository is a _much_ better approach to solving these issues.
And as such, libkookie was started: the general idea is that it
includes all nix expressions that are relevant to _any_ of my
computers. Under `roots`, a machine can have it's primary
configuration file which is built andcopied into the nix store, so
that nixpkgs can always point at the version a generation was built
with, not what is on disk).
Overlays contains everything that kookiepkgs used to, modules contains
both system-level modules (only required on NixOS), as well as
anything that is being built with home-manager. Modules are all kept
in the same tree, however some require system-level access while
others don't. There could be some kind of list to distinguish the two,
so that userspace-only systems can still take advantage of libkookie.
Diffstat (limited to 'home-manager/tests/default.nix')
-rw-r--r-- | home-manager/tests/default.nix | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/home-manager/tests/default.nix b/home-manager/tests/default.nix new file mode 100644 index 00000000000..4bda0474f88 --- /dev/null +++ b/home-manager/tests/default.nix @@ -0,0 +1,52 @@ +{ pkgs ? import <nixpkgs> {} }: + +let + + nmt = pkgs.fetchFromGitLab { + owner = "rycee"; + repo = "nmt"; + rev = "89fb12a2aaa8ec671e22a033162c7738be714305"; + sha256 = "07yc1jkgw8vhskzk937k9hfba401q8rn4sgj9baw3fkjl9zrbcyf"; + }; + +in + +import nmt { + inherit pkgs; + modules = import ../modules/modules.nix { inherit pkgs; lib = pkgs.lib; }; + testedAttrPath = [ "home" "activationPackage" ]; + tests = { + browserpass = ./modules/programs/browserpass.nix; + files-executable = ./modules/files/executable.nix; + files-hidden-source = ./modules/files/hidden-source.nix; + files-source-with-spaces = ./modules/files/source-with-spaces.nix; + files-text = ./modules/files/text.nix; + git-with-email = ./modules/programs/git-with-email.nix; + git-with-most-options = ./modules/programs/git.nix; + git-with-str-extra-config = ./modules/programs/git-with-str-extra-config.nix; + mbsync = ./modules/programs/mbsync.nix; + texlive-minimal = ./modules/programs/texlive-minimal.nix; + xresources = ./modules/xresources.nix; + } + // pkgs.lib.optionalAttrs pkgs.stdenv.hostPlatform.isLinux ( + { + getmail = ./modules/programs/getmail.nix; + i3-keybindings = ./modules/services/window-managers/i3-keybindings.nix; + } + // import ./modules/misc/pam + // import ./modules/misc/xdg + // import ./modules/misc/xsession + // import ./modules/programs/firefox + // import ./modules/programs/rofi + // import ./modules/services/sxhkd + // import ./modules/systemd + ) + // import ./modules/home-environment + // import ./modules/misc/fontconfig + // import ./modules/programs/alacritty + // import ./modules/programs/bash + // import ./modules/programs/gpg + // import ./modules/programs/ssh + // import ./modules/programs/tmux + // import ./modules/programs/zsh; +} |