diff --git a/dconf.nix b/dconf.nix new file mode 100644 index 0000000..2079ceb --- /dev/null +++ b/dconf.nix @@ -0,0 +1,9 @@ +{ config, ... }: + +{ + dconf.settings = { + "org/gnome/desktop/interface" = { + color-scheme = "prefer-dark"; + }; + }; +} diff --git a/git.nix b/git.nix new file mode 100644 index 0000000..bc2c53e --- /dev/null +++ b/git.nix @@ -0,0 +1,10 @@ +{ pkgs, ... }: + +{ + # Git configuration + programs.git = { + enable = true; + userName = "Johannes Hendrik Gerard van der Weide"; + userEmail = "hertog@fsfe.org"; + }; +} diff --git a/helix.nix b/helix.nix new file mode 100644 index 0000000..3c09855 --- /dev/null +++ b/helix.nix @@ -0,0 +1,12 @@ +{ pkgs, ... }: + +{ + # Helix configuration + programs.helix = { + enable = true; + defaultEditor = false; + settings = { + theme = "adwaita-dark"; + }; + }; +} diff --git a/home.nix b/home.nix new file mode 100644 index 0000000..91e7d4c --- /dev/null +++ b/home.nix @@ -0,0 +1,23 @@ +{ config, pkgs, ... }: +{ + home = { + stateVersion = "23.05"; + username = "hertog"; + homeDirectory = "/home/hertog"; + packages = with pkgs; [ + ]; + }; + + imports = [ + # Home-manager configured program files + ./neovim.nix + ./helix.nix + ./hyfetch.nix + ./zsh.nix + ./dconf.nix + ./sway.nix + ./git.nix + ]; + + programs.home-manager.enable = true; +} diff --git a/hyfetch.nix b/hyfetch.nix new file mode 100644 index 0000000..e1d530d --- /dev/null +++ b/hyfetch.nix @@ -0,0 +1,15 @@ +{ pkgs, config, ... }: + +{ + # Hyfetch config :3 + programs.hyfetch = { + enable = true; + settings = { + preset = "bisexual"; + mode = "rgb"; + color_align = { + mode = "horizontal"; + }; + }; + }; +} diff --git a/neovim.nix b/neovim.nix new file mode 100644 index 0000000..fecda35 --- /dev/null +++ b/neovim.nix @@ -0,0 +1,26 @@ +{ config, pkgs, ... }: + +{ + programs.neovim = { + enable = true; + defaultEditor = true; + vimAlias = true; + coc = { + enable = true; + }; + # VimRC + extraConfig = '' + set background=dark + colorscheme PaperColor + ''; + extraLuaConfig = '' + print("Welcome to Vim Hertog! :3") + ''; + # Plugins + plugins = with pkgs.vimPlugins; [ + vim-nix + nvim-treesitter-parsers.cpp + papercolor-theme + ]; + }; +} diff --git a/sway.nix b/sway.nix new file mode 100644 index 0000000..582df2e --- /dev/null +++ b/sway.nix @@ -0,0 +1,172 @@ +{ config, pkgs, ... }: + +{ + # Wofi + programs.wofi = { + enable = true; + settings = { + gtk_dark = true; + location = "left"; + allow_markup = true; + width = 250; + }; + style = '' + * { + font-family: monospace; + } + + window { + background-color: #242424; + } + + #input { + margin: 5px; + border: none; + color: #ffffff; + background-color: #b30000; + } + + #text { + margin: 5px; + border: none; + color: #ffffff; + } + + #entry { + border: none; + } + + #entry:focus { + border: none; + } + + #entry:selected { + background-color: #b30000; + border-radius: 5px; + border: none; + } + ''; + }; + + # Waybar + programs.waybar = { + enable = true; + systemd = { + enable = true; + target = "sway-session.target"; + }; + settings = { + mainBar = { + layer = "top"; + position = "top"; + height = 20; + + modules-left = [ "sway/workspaces" "sway/mode" ]; + + "sway/workspaces" = { + disable-scroll = true; + all-outputs = true; + }; + + modules-center = [ "clock" ]; + + "clock" = { + format = "{:%H:%M}"; + format-alt = "{ %A, %d %B, %Y}"; + tooltip-format = "{:%d %B, %Y}\n{calendar}"; + }; + + modules-right = [ "network" "battery" ]; + + "network" = { + format-wifi = "W{signalStrength} "; + format-ethernet = "E{signalStrength} "; + format-disconnected = "Offline"; + tooltip-format = "{ifname}: {ipaddr}"; + tooltip-format-wifi = "{essid} ({signalStrength}%): {ipaddr}"; + }; + "battery" = { + states = { + warning = 30; + critical = 15; + }; + format = "B{capacity}% "; + format-alt = "{time} {icon}"; + }; + }; + }; + style = '' + * { + border: none; + border-radius: 0; + font-family: monospace; + } + window#waybar { + background: #242424; + color: #ffffff; + } + #workspaces button { + padding: 0 5px; + background-color: #1e1e1e; + color: #ffffff; + } + #workspaces button:hover { + background: #303030; + color: #ffffff; + } + #workspaces button.focused { + background: #b30000; + color: #ffffff; + } + ''; + }; + + # Sway itself + wayland.windowManager.sway = { + enable = true; + wrapperFeatures.gtk = true; + systemd.enable = true; + config = rec { + modifier = "Mod4"; + terminal = "alacritty"; + menu = "wofi --show drun"; + startup = [ + {command = "export QT_QPA_PLATFORM=wayland";} + {command = "swaybg -i Afbeeldingen/AchterGronden/blobcat_hertog.svg";} + {command = "flatpak run org.keepassxc.KeePassXC";} + ]; + colors = { + background = "#242424"; + focused = { + indicator = "#b30000"; + background = "#b30000"; + border = "#b30000"; + childBorder = "#b30000"; + text = "#ffffff"; + }; + focusedInactive = { + indicator = "#303030"; + background = "#303030"; + border = "#303030"; + childBorder = "#303030"; + text = "#ffffff"; + }; + unfocused = { + indicator = "#1e1e1e"; + background = "#1e1e1e"; + border = "#1e1e1e"; + childBorder = "#1e1e1e"; + text = "#ffffff"; + }; + }; + bars = [ + { + command = "waybar"; + } + ]; + window = { + titlebar = false; + }; + }; + }; +} diff --git a/zsh.nix b/zsh.nix new file mode 100644 index 0000000..94b74b0 --- /dev/null +++ b/zsh.nix @@ -0,0 +1,35 @@ +{ pkgs, ... }: + +{ + # Zsh config + programs.zsh = { + enable = true; + initExtra = " + hyfetch + "; + shellAliases = { + ll = "ls -l"; + please = "sudo"; + }; + plugins = [ + { + name = "zsh-nix-shell"; + file = "nix-shell.plugin.zsh"; + src = pkgs.fetchFromGitHub { + owner = "chisui"; + repo = "zsh-nix-shell"; + rev = "v0.7.0"; + sha256 = "149zh2rm59blr2q458a5irkfh82y3dwdich60s9670kl3cl5h2m1"; + }; + } + ]; + oh-my-zsh = { + enable = true; + plugins = [ + "git" + "sudo" + ]; + theme = "mh"; + }; + }; +}