nix machine / user configurations

stuff

+2 -2
.envrc
···
-
watch_file shell/* flake.nix
-
use flake || use nix
···
+
watch_file shells/* flake.nix flake.lock
+
eval "$(nix print-dev-env)"
+7 -7
flake.lock
···
},
"latest": {
"locked": {
-
"lastModified": 1649225869,
-
"narHash": "sha256-u1zLtPmQzhT9mNXyM8Ey9pk7orDrIKdwooeGDEXm5xM=",
"owner": "nixos",
"repo": "nixpkgs",
-
"rev": "b6966d911da89e5a7301aaef8b4f0a44c77e103c",
"type": "github"
},
"original": {
···
},
"nixos": {
"locked": {
-
"lastModified": 1649504202,
-
"narHash": "sha256-k7BZoTGeNqz+jy0v0kKl3jSa+6Q4Dx1FPpZFF9+u9nA=",
"owner": "nixos",
"repo": "nixpkgs",
-
"rev": "27b0c3988745d1b18607744badaf2add79c8bcea",
"type": "github"
},
"original": {
"owner": "nixos",
-
"ref": "release-21.11",
"repo": "nixpkgs",
"type": "github"
}
···
},
"latest": {
"locked": {
+
"lastModified": 1649408932,
+
"narHash": "sha256-JhTW1OtS5fACcRXLqcTTQyYO5vLkO+bceCqeRms13SY=",
"owner": "nixos",
"repo": "nixpkgs",
+
"rev": "42948b300670223ca8286aaf916bc381f66a5313",
"type": "github"
},
"original": {
···
},
"nixos": {
"locked": {
+
"lastModified": 1649490789,
+
"narHash": "sha256-YrhVxwoofZSx/wLZ4GYET//8vS+uqWX572zvdmP/Etg=",
"owner": "nixos",
"repo": "nixpkgs",
+
"rev": "c86185d20d708013caf97a6adaa8dc6d72313c75",
"type": "github"
},
"original": {
"owner": "nixos",
+
"ref": "nixos-21.11",
"repo": "nixpkgs",
"type": "github"
}
+1 -1
flake.nix
···
description = "config!!!";
inputs = {
-
nixos.url = "github:nixos/nixpkgs/release-21.11";
latest.url = "github:nixos/nixpkgs/nixos-unstable";
home.url = "github:nix-community/home-manager/release-21.11";
···
description = "config!!!";
inputs = {
+
nixos.url = "github:nixos/nixpkgs/nixos-21.11";
latest.url = "github:nixos/nixpkgs/nixos-unstable";
home.url = "github:nix-community/home-manager/release-21.11";
+1
hosts/default.nix
···
modules =
baseModules
++ [
{nixpkgs.pkgs = pkgs;}
(import (./. + "/${name}/default.nix"))
];
···
modules =
baseModules
++ [
+
{networking.hostName = name;}
{nixpkgs.pkgs = pkgs;}
(import (./. + "/${name}/default.nix"))
];
+2
modules/base/hm-system-defaults.nix
···
{config, ...}: {
home-manager.useGlobalPkgs = true;
home-manager.sharedModules = [
{
home.sessionVariables = {inherit (config.environment.sessionVariables) NIX_PATH;};
xdg.configFile."nix/registry.json".text = config.environment.etc."nix/registry.json".text;
}
];
}
···
{config, ...}: {
home-manager.useGlobalPkgs = true;
+
home-manager.useUserPackages = true;
home-manager.sharedModules = [
{
home.sessionVariables = {inherit (config.environment.sessionVariables) NIX_PATH;};
xdg.configFile."nix/registry.json".text = config.environment.etc."nix/registry.json".text;
+
xdg.configFile."nix/nix.conf".source = config.environment.etc."nix/nix.conf".source;
}
];
}
+2
modules/base/nix.nix
···
keep-outputs = true
keep-derivations = true
fallback = true
'';
useSandbox = true;
allowedUsers = ["@wheel"];
trustedUsers = ["root" "@wheel"];
autoOptimiseStore = true;
};
}
···
keep-outputs = true
keep-derivations = true
fallback = true
+
extra-experimental-features = nix-command flakes
'';
useSandbox = true;
allowedUsers = ["@wheel"];
trustedUsers = ["root" "@wheel"];
autoOptimiseStore = true;
+
nixPath = ["nixpkgs=${inputs.latest}" "home-manager=${inputs.home}"];
};
}
+1 -1
modules/cachix/default.nix
···
filterCaches = key: value: value == "regular" && lib.hasSuffix ".nix" key && key != "default.nix";
imports = lib.mapAttrsToList toImport (lib.filterAttrs filterCaches (builtins.readDir folder));
in {
-
#inherit imports;
nix.binaryCaches = ["https://cache.nixos.org/"];
}
···
filterCaches = key: value: value == "regular" && lib.hasSuffix ".nix" key && key != "default.nix";
imports = lib.mapAttrsToList toImport (lib.filterAttrs filterCaches (builtins.readDir folder));
in {
+
inherit imports;
nix.binaryCaches = ["https://cache.nixos.org/"];
}
-6
modules/cachix/harmony.nix
···
-
{
-
nix = {
-
settings.substituters = ["https://harmony.cachix.org"];
-
binaryCachePublicKeys = ["harmony.cachix.org-1:yv78QZHgS0UHkrMW56rccNghWHRz18fFRl8mWQ63M6E="];
-
};
-
}
···
-6
modules/cachix/nix-cargo-integration.nix
···
-
{
-
nix = {
-
settings.substituters = ["https://nix-cargo-integration.cachix.org"];
-
binaryCachePublicKeys = ["nix-cargo-integration.cachix.org-1:wphySON/RyTC2DCzwKPBQGLEZv5mj0s1I1lsfQObaLs="];
-
};
-
}
···
+1 -1
modules/cachix/nix-community.nix
···
{
nix = {
-
settings.substituters = ["https://nix-community.cachix.org"];
binaryCachePublicKeys = ["nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="];
};
}
···
{
nix = {
+
binaryCaches = ["https://nix-community.cachix.org"];
binaryCachePublicKeys = ["nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="];
};
}
-6
modules/cachix/nixpkgs-wayland.nix
···
-
{
-
nix = {
-
settings.substituters = ["https://nixpkgs-wayland.cachix.org"];
-
binaryCachePublicKeys = ["nixpkgs-wayland.cachix.org-1:3lwxaILxMRkVhehr5StQprHdEo4IrE8sRho9R9HOLYA="];
-
};
-
}
···
-6
modules/cachix/nrdxp.nix
···
-
{
-
nix = {
-
settings.substituters = ["https://nrdxp.cachix.org"];
-
binaryCachePublicKeys = ["nrdxp.cachix.org-1:Fc5PSqY2Jm1TrWfm88l6cvGWwz3s93c6IOifQWnhNW4="];
-
};
-
}
···
-6
modules/cachix/veloren-nix.nix
···
-
{
-
nix = {
-
settings.substituters = ["https://veloren-nix.cachix.org"];
-
binaryCachePublicKeys = ["veloren-nix.cachix.org-1:zokfKJqVsNV6kI/oJdLF6TYBdNPYGSb+diMVQPn/5Rc="];
-
};
-
}
···
+4
pkgs-set/from-unstable.nix
···
alejandra
rnix-lsp
chromium
rofi-wayland
vscode
;
}
···
alejandra
rnix-lsp
chromium
+
rofi
rofi-wayland
vscode
+
nixUnstable
+
nix-direnv
+
direnv
;
}
-12
users/patriot/default.nix
···
"${mod}+q" = "kill";
"${mod}+Shift+e" = "exit";
"${mod}+Shift+r" = "reload";
-
"${mod}+c" = mkRofiCmd ["-show" "calc"];
# Screenshot and copy it to clipboard
"Mod1+s" = ''
exec export SFILE="${shotFile}.png" && ${grim} "$SFILE" && ${cat} "$SFILE" | ${wl-copy} -t image/png
···
cycle = true;
font = fontComb;
terminal = pkgBin "alacritty";
-
plugins = with pkgs; [
-
rofi-calc
-
rofi-systemd
-
rofi-file-browser
-
rofi-power-menu
-
];
-
extraConfig = {
-
modi = "drun,calc,file-browser-extended,ssh,keys";
-
};
};
vscode = {
enable = true;
···
theme = "mytheme"
[editor]
line-number = "relative"
-
[lsp]
-
display-messages = true
'';
"helix/languages.toml".text = ''
[[language]]
···
"${mod}+q" = "kill";
"${mod}+Shift+e" = "exit";
"${mod}+Shift+r" = "reload";
# Screenshot and copy it to clipboard
"Mod1+s" = ''
exec export SFILE="${shotFile}.png" && ${grim} "$SFILE" && ${cat} "$SFILE" | ${wl-copy} -t image/png
···
cycle = true;
font = fontComb;
terminal = pkgBin "alacritty";
};
vscode = {
enable = true;
···
theme = "mytheme"
[editor]
line-number = "relative"
'';
"helix/languages.toml".text = ''
[[language]]