2023-05-01 16:48:53 +02:00
|
|
|
{ config, pkgs, ... }:
|
2023-04-16 19:29:38 +02:00
|
|
|
|
|
|
|
let
|
|
|
|
user = "exu";
|
|
|
|
hostname = "nixos";
|
2023-05-06 20:57:11 +02:00
|
|
|
in {
|
|
|
|
imports = [ <home-manager/nixos> ];
|
2023-04-16 19:29:38 +02:00
|
|
|
|
2023-04-17 21:14:39 +02:00
|
|
|
# root home
|
2023-04-17 21:32:54 +02:00
|
|
|
home-manager.users.root = { pkgs, ... }: {
|
|
|
|
home.username = "root";
|
|
|
|
home.homeDirectory = "/root";
|
|
|
|
home.stateVersion = "22.11";
|
2023-05-06 20:57:11 +02:00
|
|
|
home.packages = with pkgs;
|
|
|
|
[
|
|
|
|
kitty # terminfo support
|
|
|
|
];
|
2023-04-17 21:32:54 +02:00
|
|
|
|
2023-05-06 20:57:11 +02:00
|
|
|
imports = [ ./home-manager/hyprland.nix ./home-manager/fish.nix ];
|
2023-04-18 17:02:45 +02:00
|
|
|
|
2023-04-17 21:32:54 +02:00
|
|
|
};
|
2023-04-17 21:14:39 +02:00
|
|
|
|
2023-04-17 21:02:17 +02:00
|
|
|
# keep everything using home manager within this block
|
2023-04-16 19:29:38 +02:00
|
|
|
home-manager.users.${user} = { pkgs, ... }: {
|
2023-04-17 21:02:17 +02:00
|
|
|
home.username = "${user}";
|
|
|
|
home.homeDirectory = "/home/${user}";
|
2023-04-16 19:29:38 +02:00
|
|
|
home.stateVersion = "22.11";
|
2023-04-17 21:14:39 +02:00
|
|
|
home.packages = with pkgs; [
|
|
|
|
firefox # browser
|
|
|
|
kitty # terminal
|
|
|
|
pciutils # lspci command
|
|
|
|
git # git
|
|
|
|
emacs # emacs editor
|
|
|
|
acpilight # controlling laptop monitor backlight
|
|
|
|
networkmanagerapplet # network configuration
|
|
|
|
wofi # app launcher (wayland replacement for rofi)
|
|
|
|
fish # fish shell
|
2023-04-18 18:07:19 +02:00
|
|
|
libnotify # notifications
|
2023-04-18 18:40:25 +02:00
|
|
|
xdg-desktop-portal-hyprland # desktop portal (hyprland fork)
|
2023-05-01 12:49:53 +02:00
|
|
|
#neovim # text editor
|
2023-05-16 17:36:02 +02:00
|
|
|
dunst # notification daemon
|
2023-05-01 12:33:34 +02:00
|
|
|
yt-dlp # video downloader
|
2023-05-01 14:59:04 +02:00
|
|
|
#sweet # gtk theme
|
2023-05-01 16:23:51 +02:00
|
|
|
waybar # status bar
|
2023-05-01 17:39:08 +02:00
|
|
|
playerctl # mpris
|
2023-05-02 16:49:18 +02:00
|
|
|
xfce.thunar # file manager
|
2023-05-02 17:01:50 +02:00
|
|
|
xfce.thunar-archive-plugin # manage archives in thunar
|
2023-05-02 18:52:16 +02:00
|
|
|
#xfce.xfce4-settings # xfce settings manager
|
2023-05-02 18:46:36 +02:00
|
|
|
xfce.xfconf # xfce config storage
|
2023-05-05 14:58:36 +02:00
|
|
|
transmission-remote-gtk # torrent remote controll gui
|
2023-05-06 21:42:42 +02:00
|
|
|
libreoffice-fresh # office document editor
|
2023-05-06 21:31:50 +02:00
|
|
|
hunspell # offline spellchecker (en)
|
|
|
|
hunspellDicts.de_CH # adds German (Switzerland) for hunspell
|
2023-05-16 17:36:02 +02:00
|
|
|
discord # install discord
|
|
|
|
udiskie # user disk mounting
|
2023-04-16 19:29:38 +02:00
|
|
|
];
|
2023-04-17 20:31:22 +02:00
|
|
|
|
2023-05-06 20:57:11 +02:00
|
|
|
imports = [ ./home-manager/hyprland.nix ./home-manager/fish.nix ];
|
2023-04-18 17:11:04 +02:00
|
|
|
|
2023-05-01 12:06:16 +02:00
|
|
|
systemd.user = {
|
|
|
|
# user services
|
|
|
|
services = {
|
|
|
|
# ssh-agent user service
|
|
|
|
ssh-agent = {
|
2023-05-06 20:57:11 +02:00
|
|
|
Unit = { Description = "SSH key agent"; };
|
2023-05-01 12:06:16 +02:00
|
|
|
Service = {
|
|
|
|
Type = "simple";
|
|
|
|
Environment = "SSH_AUTH_SOCK=%t/ssh-agent.socket";
|
2023-05-05 12:33:33 +02:00
|
|
|
ExecStart = "${pkgs.openssh}/bin/ssh-agent -D -a $SSH_AUTH_SOCK";
|
2023-05-01 12:06:16 +02:00
|
|
|
};
|
2023-05-06 20:57:11 +02:00
|
|
|
Install = { WantedBy = [ "default.target" ]; };
|
2023-05-01 11:38:22 +02:00
|
|
|
};
|
|
|
|
};
|
2023-05-01 12:06:16 +02:00
|
|
|
# user environment variables
|
|
|
|
sessionVariables = {
|
2023-05-05 12:56:17 +02:00
|
|
|
# see https://discourse.nixos.org/t/how-to-use-xdg-runtime-dir-in-pam-sessionvariables/10120/3 about the builtin variable
|
2023-05-06 20:57:11 +02:00
|
|
|
SSH_AUTH_SOCK = "${builtins.getEnv "XDG_RUNTIME_DIR"}/ssh-agent.socket";
|
2023-05-01 12:06:16 +02:00
|
|
|
};
|
2023-05-01 11:38:22 +02:00
|
|
|
};
|
|
|
|
|
2023-05-01 13:32:34 +02:00
|
|
|
# git configuration
|
2023-05-01 13:36:03 +02:00
|
|
|
programs.git = {
|
|
|
|
enable = true;
|
|
|
|
extraConfig = {
|
2023-05-06 20:57:11 +02:00
|
|
|
init = { defaultBranch = "main"; };
|
2023-05-01 13:36:03 +02:00
|
|
|
user = {
|
|
|
|
name = "RealStickman";
|
|
|
|
email = "mrc@frm01.net";
|
|
|
|
};
|
2023-05-06 20:57:11 +02:00
|
|
|
gitlab = { user = "RealStickman"; };
|
|
|
|
github = { user = "RealStickman"; };
|
2023-05-01 13:32:34 +02:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2023-05-05 14:58:36 +02:00
|
|
|
programs = {
|
|
|
|
waybar = {
|
|
|
|
enable = true;
|
|
|
|
settings = {
|
2023-05-06 20:57:11 +02:00
|
|
|
mainBar = (builtins.fromJSON
|
|
|
|
(builtins.readFile ./home-manager/config/waybar/config.json));
|
2023-05-05 14:58:36 +02:00
|
|
|
};
|
|
|
|
style = (builtins.readFile ./home-manager/config/waybar/style.css);
|
|
|
|
};
|
|
|
|
kitty = {
|
|
|
|
enable = true;
|
2023-05-06 20:57:11 +02:00
|
|
|
extraConfig =
|
|
|
|
(builtins.readFile ./home-manager/config/kitty/kitty.conf);
|
2023-05-05 14:58:36 +02:00
|
|
|
};
|
|
|
|
ssh = {
|
|
|
|
enable = true;
|
2023-05-06 21:15:02 +02:00
|
|
|
extraOptionOverrides = { AddKeysToAgent = "yes"; };
|
2023-05-06 21:23:15 +02:00
|
|
|
matchBlocks = {
|
|
|
|
"gitlab.com" = {
|
2023-05-05 14:58:36 +02:00
|
|
|
host = "gitlab.com";
|
2023-05-06 21:15:02 +02:00
|
|
|
identityFile = [ "/home/${user}/.ssh/id_ed25519_git" ];
|
2023-05-06 21:23:15 +02:00
|
|
|
};
|
|
|
|
"github.com" = {
|
2023-05-05 14:58:36 +02:00
|
|
|
host = "github.com";
|
2023-05-06 21:15:02 +02:00
|
|
|
identityFile = [ "/home/${user}/.ssh/id_ed25519_git" ];
|
2023-05-06 21:23:15 +02:00
|
|
|
};
|
|
|
|
"gitea.exu.li" = {
|
2023-05-05 14:58:36 +02:00
|
|
|
host = "gitea.exu.li";
|
2023-05-06 21:15:02 +02:00
|
|
|
identityFile = [ "/home/${user}/.ssh/id_ed25519_git" ];
|
2023-05-06 21:23:15 +02:00
|
|
|
};
|
|
|
|
"aur.archlinux.org" = {
|
2023-05-05 14:58:36 +02:00
|
|
|
host = "aur.archlinux.org";
|
2023-05-06 21:15:02 +02:00
|
|
|
identityFile = [ "/home/${user}/.ssh/id_ed25519_git" ];
|
2023-05-06 21:23:15 +02:00
|
|
|
};
|
|
|
|
};
|
2023-05-01 16:52:08 +02:00
|
|
|
};
|
2023-05-01 16:23:51 +02:00
|
|
|
};
|
|
|
|
|
2023-05-16 17:37:32 +02:00
|
|
|
services.dunst = { enable = false; };
|
2023-05-16 17:36:02 +02:00
|
|
|
|
2023-05-01 21:29:17 +02:00
|
|
|
home.file = {
|
2023-05-02 16:49:18 +02:00
|
|
|
# Scripts
|
2023-05-01 21:29:17 +02:00
|
|
|
".scripts/waybar/player-mpris-tail.py" = {
|
|
|
|
source = ./home-manager/scripts/waybar/player-mpris-tail.py;
|
|
|
|
executable = true;
|
|
|
|
};
|
2023-05-02 16:49:18 +02:00
|
|
|
# Thunar configuration
|
2023-05-02 18:25:59 +02:00
|
|
|
".config/Thunar" = {
|
2023-05-02 16:49:18 +02:00
|
|
|
source = ./home-manager/config/Thunar;
|
2023-05-02 18:25:59 +02:00
|
|
|
#recursive = true;
|
2023-05-02 16:49:18 +02:00
|
|
|
};
|
|
|
|
# templates
|
2023-05-02 18:25:59 +02:00
|
|
|
".config/Vorlagen" = {
|
2023-05-02 16:49:18 +02:00
|
|
|
source = ./home-manager/config/Vorlagen;
|
2023-05-02 18:25:59 +02:00
|
|
|
#recursive = true;
|
2023-05-02 16:49:18 +02:00
|
|
|
};
|
2023-05-02 18:25:59 +02:00
|
|
|
# xfce4 settings
|
2023-05-02 18:52:24 +02:00
|
|
|
".config/xfce4".source = ./home-manager/config/xfce4;
|
2023-05-02 17:26:11 +02:00
|
|
|
# xdg user dirs
|
|
|
|
".config/user-dirs.dirs".source = ./home-manager/config/user-dirs.dirs;
|
|
|
|
# xdg user locales
|
2023-05-06 20:57:11 +02:00
|
|
|
".config/user-dirs.locale".source =
|
|
|
|
./home-manager/config/user-dirs.locale;
|
2023-05-05 14:58:36 +02:00
|
|
|
# libreoffice settings
|
2023-05-16 17:19:48 +02:00
|
|
|
#".config/libreoffice".source = ./home-manager/config/libreoffice;
|
2023-05-05 14:58:36 +02:00
|
|
|
# transmission remote settings
|
2023-05-06 20:57:11 +02:00
|
|
|
".config/transmission-remote-gtk".source =
|
|
|
|
./home-manager/config/transmission-remote-gtk;
|
2023-05-05 14:58:36 +02:00
|
|
|
# TODO firefox configuration
|
2023-05-05 15:00:38 +02:00
|
|
|
# TODO calibre configuration
|
2023-05-16 17:36:02 +02:00
|
|
|
# dunst configuration
|
|
|
|
# TODO replace using the built-in dunst support of home-manager
|
|
|
|
".config/dunst/dunstrc".source = ./home-manager/config/dunst/dunstrc;
|
2023-05-01 21:29:17 +02:00
|
|
|
};
|
2023-05-01 13:52:14 +02:00
|
|
|
|
2023-04-17 20:31:22 +02:00
|
|
|
};
|
2023-04-16 19:29:38 +02:00
|
|
|
}
|