nixconfig/home.nix

334 lines
8.7 KiB
Nix

{ inputs, config, lib, pkgs, ... }:
{
#home-manager.users.insert= { pkgs, ... }: {
imports = [
./home-files.nix
];
home.packages = [
pkgs.git
pkgs.fluffychat
pkgs.cinny-desktop
pkgs.firefox
pkgs.kate
pkgs.godot_4
pkgs.filezilla
pkgs.libsForQt5.lightly
pkgs.pfetch
pkgs.git-credential-oauth
pkgs.wayvnc
pkgs.android-tools
pkgs.gnome.eog
pkgs.libsForQt5.gwenview
pkgs.libsForQt5.qtstyleplugins
pkgs.libsForQt5.qt5ct
pkgs.oh-my-zsh
pkgs.kubectl
pkgs.kubernetes-helm
pkgs.vscodium
#pkgs.atool
#pkgs.httpie
pkgs.webcord
pkgs.tigervnc
pkgs.syncthing
pkgs.zsh-syntax-highlighting
pkgs.zsh-history-substring-search
pkgs.kitty
pkgs.grim
pkgs.slurp
pkgs.prismlauncher
pkgs.glfw-wayland-minecraft
];
services.syncthing.enable = true;
programs.vscode = {
package = pkgs.vscodium;
extensions = [
pkgs.vscode-extensions.catppuccin.catppuccin-vsc
pkgs.vscode-extensions.catppuccin.catppuccin-vsc-icons
pkgs.vscode-extensions.ms-python.python
pkgs.vscode-extensions.ms-python.vscode-pylance
pkgs.vscode-extensions.jnoortheen.nix-ide
];
userSettings = {
"workbench.colorTheme" = "Catppuccin Frappé";
"workbench.iconTheme" = "catppuccin-frappe";
"git.enableSmartCommit" = true;
"editor.fontFamily" = "'Monocraft Nerd Font'";
"editor.fontSize" = 16;
"files.autoSave" = "off";
"window.menuBarVisibility" = "toggle";
};
};
gtk = {
enable = true;
iconTheme = {
name = "Papirus-Dark";
package = pkgs.papirus-icon-theme;
};
cursorTheme = {
name = "catppuccin-frappe-blue-cursors";
package = pkgs.catppuccin-cursors.frappeBlue;
size = 24;
};
theme = {
name = "catppuccin-frappe-mauve-standard";
package = pkgs.catppuccin-gtk.override {
accents = [ "mauve" ];
size = "standard";
#tweaks = [ "black" ];
variant = "frappe";
};
};
gtk3.extraConfig = {
Settings = ''
gtk-application-prefer-dark-theme=1
'';
};
gtk4.extraConfig = {
Settings = ''
gtk-application-prefer-dark-theme=1
'';
};
};
home.pointerCursor = {
name = "catppuccin-frappe-blue-cursors";
package = pkgs.catppuccin-cursors.frappeBlue;
size = 24;
x11 = {
enable = true;
defaultCursor = "catppuccin-frappe-blue-cursors";
};
};
programs.nnn = {
enable = true;
#plugins = { "launch", "imgview" };
plugins.src = (pkgs.fetchFromGitHub {
owner = "jarun";
repo = "nnn";
rev = "v4.9";
sha256 = "sha256-Hpc8YaJeAzJoEi7aJ6DntH2VLkoR6ToP6tPYn3llR7k=";
}) + "/plugins";
plugins.mappings = {
l = "launch";
v = "imgview";
g = "getplugs";
};
};
accounts.email = {
accounts.insert = {
address = "insert@insertapp.net";
gpg = {
key = "A70775C389ACF105";
signByDefault = true;
};
imap.host = "imap.purelymail.com";
imap.port = 993;
primary = true;
realName = "Insert";
smtp = {
host = "smtp.purelymail.com";
port = 465;
};
passwordCommand = "cat ${config.age.secrets.email.path}";
userName = "insert@insertapp.net";
#notmuch.enable = true;
thunderbird.enable = true;
};
};
#programs.notmuch.enable = true;
programs.himalaya.enable = false;
programs.thunderbird = {
enable = true;
profiles.insert = {
#name = "Insert";
isDefault = true;
withExternalGnupg = false;
settings = {"mail.openpgp.alternative_gpg_path" = "/run/current-system/sw/bin/gpg-agent";};
};
};
programs.librewolf.enable = true;
programs.git = {
enable = true;
userName = "insert";
userEmail = "insert@insertapp.net";
signing = {
key = "A70775C389ACF105";
signByDefault = true;
};
};
#programs.thefuck.enable = true;
programs.git-credential-oauth.enable = true;
programs.kitty = {
enable = true;
theme = "Catppuccin-Frappe";
settings = {
font_family = "Monocraft Nerd Font";
};
};
programs.zsh = {
enable = true;
shellAliases = {
update = "nh os switch -a /home/insert/Documents/nixos -- --impure --option commit-lockfile-summary 'Update flake.lock' --commit-lock-file";
update-locked = "nh os switch -a /home/insert/Documents/nixos -- --impure";
update-boot = "nh os boot -a /home/insert/Documents/nixos -- --impure";
garbage = "nix-collect-garbage";
};
initExtra = ''
source ~/.p10k.zsh
export TERM=xterm-256color
PF_INFO="ascii title os kernel uptime pkgs memory wm de palette" pfetch
'';
plugins = [
{name = "powerlevel10k";src = pkgs.zsh-powerlevel10k;file = "share/zsh-powerlevel10k/powerlevel10k.zsh-theme";}
{
name = "zsh-nix-shell";
file = "nix-shell.plugin.zsh";
src = pkgs.fetchFromGitHub {
owner = "chisui";
repo = "zsh-nix-shell";
rev = "v0.8.0";
sha256 = "1lzrn0n4fxfcgg65v0qhnj7wnybybqzs4adz7xsrkgmcsr0ii8b7";
};
}
];
syntaxHighlighting.enable = true;
historySubstringSearch.enable = true;
autosuggestion.enable = true;
oh-my-zsh = {
enable = true;
plugins = [ "git" "kubectl" ];
#theme = "powerlevel10k/powerlevel10k";
};
};
home.sessionVariables = {
NIXOS_OZONE_WL = "1";
KUBECONFIG = "/home/insert/Desktop/k3s.yaml";
QT_QPA_PLATFORMTHEME = "qt5ct";
ELECTRON_OZONE_PLATFORM_HINT = "auto";
WLR_NO_HARDWARE_CURSORS = "1";
NO_HARDWARE_CURSORS = "true";
};
programs.swaylock.enable = false;
wayland.windowManager.sway = {
enable = true;
wrapperFeatures.gtk = true;
checkConfig = true;
extraOptions = [ "--unsupported-gpu" ];
config = rec {
menu = "wofi --show drun --allow-images";
defaultWorkspace = "workspace number 1";
floating.border = 4;
window.border = 4;
terminal = "kitty";
gaps = {
inner = 5;
outer = 10;
};
colors = {
background = "#303446";
focused = {
childBorder = "#ca9ee6";
background = "#ca9ee6";
text = "#c6d0f5";
indicator = "#ca9ee6";
border = "#ca9ee6";
};
unfocused = {
childBorder = "#949cbb";
background = "#626880";
text = "#c6d0f5";
indicator = "#949cbb";
border = "#949cbb";
};
focusedInactive = {
childBorder = "#949cbb";
background = "#626880";
text = "#c6d0f5";
indicator = "#949cbb";
border = "#949cbb";
};
urgent = {
childBorder = "#ef9f76";
background = "#626880";
text = "#ef9f76";
indicator = "#ef9f76";
border = "#ef9f76";
};
placeholder = {
childBorder = "#949cbb";
background = "#626880";
text = "#c6d0f5";
indicator = "#949cbb";
border = "#949cbb";
};
};
keybindings = let
modifier = config.wayland.windowManager.sway.config.modifier;
in lib.mkOptionDefault {
#"''${modifier}+Return" = "exec ${cfg.config.terminal}";
"${modifier}+c" = "kill";
"${modifier}+r" = "exec ${config.wayland.windowManager.sway.config.menu}";
"${modifier}+p" = "exec grim -g \"\$(slurp)\" - | wl-copy";
"${modifier}+v" = "floating toggle";
};
startup = [
# Launch Firefox on start
{command = "wayvnc 100.120.210.58";}
{command = "swww-daemon";}
{command = "mako";}
{command = "exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway";}
];
bars = [
{command = "waybar"; position = "top"; }
];
};
#https://github.com/catppuccin/i3/blob/main/themes/catppuccin-frappe
extraConfig = ''set $rosewater #f2d5cf
set $flamingo #eebebe
set $pink #f4b8e4
set $mauve #ca9ee6
set $red #e78284
set $maroon #ea999c
set $peach #ef9f76
set $yellow #e5c890
set $green #a6d189
set $teal #81c8be
set $sky #99d1db
set $sapphire #85c1dc
set $blue #8caaee
set $lavender #babbf1
set $text #c6d0f5
set $subtext1 #b5bfe2
set $subtext0 #a5adce
set $overlay2 #949cbb
set $overlay1 #838ba7
set $overlay0 #737994
set $surface2 #626880
set $surface1 #51576d
set $surface0 #414559
set $base #303446
set $mantle #292c3c
set $crust #232634'';
};
home.stateVersion = "23.05";
programs.home-manager.enable = true;
}