huge progress dump, impermanence
This commit is contained in:
parent
3feb92cec5
commit
fce64637c2
13 changed files with 161 additions and 81 deletions
|
@ -32,7 +32,7 @@ in {
|
|||
];
|
||||
|
||||
services.emacs = {
|
||||
enable = false;
|
||||
enable = true;
|
||||
package = custom-emacs;
|
||||
};
|
||||
};
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
}: let
|
||||
cfg = config.modules.system.programs.editors.helix;
|
||||
inherit (config.modules.other.system) username;
|
||||
inherit (lib) mkIf;
|
||||
inherit (lib) mkIf getExe;
|
||||
in {
|
||||
imports = [./languages.nix];
|
||||
config = mkIf cfg.enable {
|
||||
|
@ -39,7 +39,7 @@ in {
|
|||
};
|
||||
};
|
||||
keys.normal = {
|
||||
C-g = [":new" ":insert-output ${pkgs.gitui}" ":buffer-close!" ":redraw"];
|
||||
C-g = [":new" ":insert-output ${getExe pkgs.lazygit}" ":buffer-close!" ":redraw"];
|
||||
esc = ["collapse_selection" "keep_primary_selection"];
|
||||
A-H = "goto_previous_buffer";
|
||||
A-L = "goto_next_buffer";
|
||||
|
|
|
@ -7,6 +7,5 @@ _: {
|
|||
./dunst.nix
|
||||
./mpd.nix
|
||||
./firewall.nix
|
||||
./vpn.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,12 +0,0 @@
|
|||
{pkgs, ...}: {
|
||||
services.openvpn.servers = {
|
||||
# air = {
|
||||
# config = ''
|
||||
# config /home/vali/Documents/AirVPN_Netherlands_UDP-443-Entry3.ovpn
|
||||
# script-security 2
|
||||
# up ${pkgs.update-systemd-resolved}/libexec/openvpn/update-systemd-resolved
|
||||
# down ${pkgs.update-systemd-resolved}/libexec/openvpn/update-systemd-resolved
|
||||
# '';
|
||||
# };
|
||||
};
|
||||
}
|
|
@ -16,6 +16,7 @@ in {
|
|||
|
||||
home-manager.users.${username}.home.packages = with pkgs; [
|
||||
bluetuith
|
||||
bluez
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -125,8 +125,7 @@
|
|||
"https://cache.nixos.org" # funny binary cache
|
||||
"https://nix-community.cachix.org" # nix-community cache
|
||||
"https://hyprland.cachix.org" # hyprland
|
||||
"https://nixpkgs-unfree.cachix.org" # unfree-package cache
|
||||
"https://neovim-flake.cachix.org" # a cache for nvf
|
||||
# "https://nixpkgs-unfree.cachix.org" # unfree-package cache
|
||||
"https://helix.cachix.org" # a chache for helix
|
||||
];
|
||||
|
||||
|
|
|
@ -4,29 +4,77 @@
|
|||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (lib) optionalString mkIf mkForce;
|
||||
inherit (lib) mkForce;
|
||||
inherit (builtins) map;
|
||||
|
||||
cfg = config.modules.system.impermanence;
|
||||
in {
|
||||
# config = mkIf false {
|
||||
# imports = [
|
||||
# inputs.impermanence.nixosModules.impermanence
|
||||
# ];
|
||||
# environment.persistence."/persist" = {
|
||||
# directories = [
|
||||
# "/etc/nixos"
|
||||
# "/etc/nix"
|
||||
# "/etc/NetworkManager/system-connections"
|
||||
# "/var/db/sudo"
|
||||
# "/var/lib/bluetooth"
|
||||
# "/var/lib/nixos"
|
||||
# "/var/lib/pipewire"
|
||||
# "/var/lib/systemd/coredump"
|
||||
# ];
|
||||
imports = [
|
||||
inputs.impermanence.nixosModules.impermanence
|
||||
];
|
||||
users = {
|
||||
mutableUsers = true;
|
||||
# users = {
|
||||
# cr = {
|
||||
# initialHashedPassword = "";
|
||||
# hashedPasswordFile = "/persist/passwords/cr";
|
||||
# };
|
||||
# root.hashedPasswordFile = "/persist/passwords/root";
|
||||
# };
|
||||
};
|
||||
|
||||
# files = [
|
||||
# "/etc/machine-id"
|
||||
# ];
|
||||
# };
|
||||
# };
|
||||
environment.persistence."/persist" = {
|
||||
directories = [
|
||||
"/etc/nixos"
|
||||
"/etc/nix"
|
||||
"/etc/NetworkManager/system-connections"
|
||||
"/var/db/sudo"
|
||||
"/var/log"
|
||||
"/var/lib/bluetooth"
|
||||
"/var/lib/nixos"
|
||||
"/var/lib/pipewire"
|
||||
"/var/lib/systemd/coredump"
|
||||
];
|
||||
|
||||
files = [
|
||||
"/etc/machine-id"
|
||||
];
|
||||
users.cr = {
|
||||
directories =
|
||||
[
|
||||
"cloud"
|
||||
"repos"
|
||||
".config/nicotine"
|
||||
]
|
||||
++ map (
|
||||
dir: ".config/${dir}"
|
||||
) ["nicotine" "Signal"]
|
||||
++ map (
|
||||
dir: ".cache/${dir}"
|
||||
) ["tealdeer" "keepassxc" "nix" "starship" "nix-index" "mozilla" "zsh" "nvim"]
|
||||
++ map (
|
||||
dir: ".local/share/${dir}"
|
||||
) ["direnv" "TelegramDesktop" "PrismLauncher" "nicotine" "zoxide"];
|
||||
};
|
||||
};
|
||||
|
||||
# for some reason *this* is what makes networkmanager not get screwed completely instead of the impermanence module
|
||||
systemd.tmpfiles.rules = [
|
||||
"L /var/lib/NetworkManager/secret_key - - - - /persist/var/lib/NetworkManager/secret_key"
|
||||
"L /var/lib/NetworkManager/seen-bssids - - - - /persist/var/lib/NetworkManager/seen-bssids"
|
||||
"L /var/lib/NetworkManager/timestamps - - - - /persist/var/lib/NetworkManager/timestamps"
|
||||
];
|
||||
|
||||
# services.openssh.hostKeys = mkForce [
|
||||
# {
|
||||
# bits = 4096;
|
||||
# path = "/persist/etc/ssh/ssh_host_rsa_key";
|
||||
# type = "rsa";
|
||||
# }
|
||||
# {
|
||||
# bits = 4096;
|
||||
# path = "/persist/etc/ssh/ssh_host_ed25519_key";
|
||||
# type = "ed25519";
|
||||
# }
|
||||
# ];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue