From 9e89a97d16d5cc697c3f1d9b2572609d9755c133 Mon Sep 17 00:00:00 2001 From: adikro Date: Mon, 10 Nov 2025 23:32:21 +0100 Subject: test --- home/editors/helix.nix | 7 ++ home/editors/nixvim.nix | 12 +++ home/editors/nvf.nix | 42 ++++++++ home/home.nix | 119 ++++++++++++++++++++++ home/programs/librewolf.nix | 6 ++ home/programs/nixcord.nix | 136 ++++++++++++++++++++++++++ home/programs/spicetify.nix | 22 +++++ home/shells/fish.nix | 17 ++++ home/shells/starship.nix | 10 ++ home/stylix.nix | 8 ++ home/terminals/foot.nix | 25 +++++ home/wayland/eww.nix | 7 ++ home/wayland/hyprland/binds.nix | 65 +++++++++++++ home/wayland/waybar.nix | 211 ++++++++++++++++++++++++++++++++++++++++ home/wayland/xdg.nix | 37 +++++++ 15 files changed, 724 insertions(+) create mode 100644 home/editors/helix.nix create mode 100644 home/editors/nixvim.nix create mode 100644 home/editors/nvf.nix create mode 100644 home/home.nix create mode 100644 home/programs/librewolf.nix create mode 100644 home/programs/nixcord.nix create mode 100644 home/programs/spicetify.nix create mode 100644 home/shells/fish.nix create mode 100644 home/shells/starship.nix create mode 100644 home/stylix.nix create mode 100644 home/terminals/foot.nix create mode 100644 home/wayland/eww.nix create mode 100644 home/wayland/hyprland/binds.nix create mode 100644 home/wayland/waybar.nix create mode 100644 home/wayland/xdg.nix (limited to 'home') diff --git a/home/editors/helix.nix b/home/editors/helix.nix new file mode 100644 index 0000000..0204f8d --- /dev/null +++ b/home/editors/helix.nix @@ -0,0 +1,7 @@ +{ pkgs, ... }: +{ + programs.helix = { + enable = true; +# package = pkgs.helix; + }; +} diff --git a/home/editors/nixvim.nix b/home/editors/nixvim.nix new file mode 100644 index 0000000..48792a0 --- /dev/null +++ b/home/editors/nixvim.nix @@ -0,0 +1,12 @@ +{ inputs, pkgs, ... }: +{ + imports = [ inputs.nixvim.homeModules.nixvim ]; + programs.nixvim = { + enable = true; + package = inputs.neovim-nightly-overlay.packages.${pkgs.stdenv.hostPlatform.system}.default; + extraPlugins = [ pkgs.vimPlugins.gruvbox ]; + colorscheme = "gruvbox"; + viAlias = true; + vimAlias = true; + }; +} diff --git a/home/editors/nvf.nix b/home/editors/nvf.nix new file mode 100644 index 0000000..428f41f --- /dev/null +++ b/home/editors/nvf.nix @@ -0,0 +1,42 @@ +{ inputs, pkgs, ... }: + +{ + programs.nvf = { + enable = true; + + settings.vim = { + package= inputs.neovim-nightly-overlay.packages.${pkgs.stdenv.hostPlatform.system}.default; + + viAlias = true; + vimAlias = true; + + theme = { + enable = true; + name = "gruvbox"; + style = "dark"; + }; + + statusline = { + lualine = { + enable = true; + theme = "gruvbox-material"; + }; + }; + + autopairs.nvim-autopairs.enable = true; + + lsp.enable = true; + + languages = { + nix = { + enable = true; + format = { + enable = true; + type = "alejandra"; + }; + }; + clang.enable = true; + }; + }; + }; +} diff --git a/home/home.nix b/home/home.nix new file mode 100644 index 0000000..6f18efe --- /dev/null +++ b/home/home.nix @@ -0,0 +1,119 @@ +{ pkgs, inputs, ... }: + +{ + imports = [ + ./wayland/hyprland/binds.nix + ./wayland/waybar.nix + ./terminals/foot.nix + ./shells/fish.nix + ./shells/starship.nix + ./programs/spicetify.nix +# ./editors/nvf.nix + ./editors/nixvim.nix + ./editors/helix.nix + ./wayland/xdg.nix + ./wayland/eww.nix + ./programs/librewolf.nix + ./programs/nixcord.nix +# ./stylix.nix +]; + + home.username = "adam"; + home.homeDirectory = "/home/adam"; + home.stateVersion = "25.05"; + + home.packages = with pkgs; [ + ripgrep + jq + nix-index + qbittorrent-enhanced + fastfetch + foot + wofi + inputs.awww.packages.${pkgs.stdenv.hostPlatform.system}.awww + bitwarden-desktop + yt-dlp-light + ffmpeg + mpv + gimp + obs-cmd + obs-studio + mako + satty + thunderbird + nautilus + kdePackages.dolphin + xfce.thunar-volman + xfce.thunar-vcs-plugin + xfce.thunar-archive-plugin + magic-wormhole + obsidian + xfce.thunar + alsa-utils + ]; + + programs.btop.enable = true; + +programs.git = { + enable = true; + settings = { + user.name = "adikro"; + user.email = "adikro@disroot.org"; + init.defaultBranch = "main"; + }; +}; + +gtk = { + enable = true; + theme = { + name = "Adwaita-dark"; + package = pkgs.gnome-themes-extra; + }; +}; + +qt = { + enable = true; + style.name = "Breeze-Dark"; +}; + +wayland.windowManager.hyprland = { + enable = true; + settings = { + + general = { + gaps_in = 6; + gaps_out = 16; + border_size = 2; + }; + + decoration = { + rounding = 12; + }; + + "$mod" = "ALT"; + monitor = [ + "DP-1,2560x1440@240,0x0,1,vrr,0" + ]; + workspace = [ + "1,monitor:DP-1,default:true" + "2,monitor:DP-1" + "3,monitor:DP-1" + "4,monitor:DP-1" + "5,monitor:DP-1" + ]; + + input = { + accel_profile = "flat"; + sensitivity = -0.6; + repeat_rate = 45; + repeat_delay = 750; + }; + + animations = { + enabled = false; + }; + }; +}; + + programs.home-manager.enable = true; +} diff --git a/home/programs/librewolf.nix b/home/programs/librewolf.nix new file mode 100644 index 0000000..751e04d --- /dev/null +++ b/home/programs/librewolf.nix @@ -0,0 +1,6 @@ +{ ... }: +{ + programs.librewolf = { + enable = true; + }; +} diff --git a/home/programs/nixcord.nix b/home/programs/nixcord.nix new file mode 100644 index 0000000..ead23aa --- /dev/null +++ b/home/programs/nixcord.nix @@ -0,0 +1,136 @@ +{ pkgs, inputs, lib, config, ... }: +{ + imports = [ inputs.nixcord.homeModules.nixcord ]; + + programs.nixcord = { + enable = true; + discord.enable = false; + vesktop = { + enable = true; + autoscroll.enable = true; + }; + config = { + frameless = true; + autoUpdate = true; + transparent = true; + + plugins = { + alwaysExpandRoles.enable = true; + betterGifAltText.enable = true; + betterGifPicker.enable = true; + betterNotesBox = { + enable = true; + hide = true; + }; + betterRoleContext.enable = true; + betterSettings = { + enable = true; + organizeMenu = false; + }; + betterUploadButton.enable = true; + biggerStreamPreview.enable = true; + callTimer.enable = true; + copyFileContents.enable = true; + disableCallIdle.enable = true; + dontRoundMyTimestamps.enable = true; + expressionCloner.enable = true; + favoriteEmojiFirst.enable = true; + fixSpotifyEmbeds.enable = true; + fixYoutubeEmbeds.enable = true; + forceOwnerCrown.enable = true; + friendsSince.enable = true; + fullSearchContext.enable = true; + fullUserInChatbox.enable = true; + iLoveSpam.enable = true; + imageFilename.enable = true; + imageLink.enable = true; + imageZoom = { + enable = true; + saveZoomValues = true; + square = true; + }; + memberCount.enable = true; + mentionAvatars.enable = true; + messageClickActions.enable = true; + messageLinkEmbeds.enable = true; + messageLogger = { + enable = true; + ignoreSelf = true; + }; + moyai.enable = true; + mutualGroupDMs.enable = true; + newGuildSettings = { + enable = true; + messages = "only@Mentions"; + }; + noDevtoolsWarning.enable = true; + noF1.enable = true; + noMosaic.enable = true; + noPendingCount = { + enable = true; + hideFriendRequestsCount = false; + hideMessageRequestCount = false; + }; + noProfileThemes.enable = true; + noTrack.enable = true; + noTypingAnimation.enable = true; + onePingPerDM.enable = true; + openInApp.enable = true; + pauseInvitesForever.enable = true; + permissionFreeWill = { + enable = true; + lockout = false; + }; + permissionsViewer.enable = true; + pinDMs = { + enable = true; + dmSectioncollapsed = true; + }; + platformIndicators.enable = true; + relationshipNotifier.enable = true; + roleColorEverywhere.enable = true; + sendTimestamps.enable = true; + serverInfo.enable = true; + settings.enable = false; + showConnections.enable = true; + showHiddenChannels.enable = true; + showHiddenThings.enable = true; + showTimeoutDuration.enable = true; + sortFriendRequests = { + enable = true; + showDates = true; + }; + spotifyControls = { + enable = true; + useSpotifyUris = true; + }; + spotifyCrack = { + enable = true; + noSpotifyAutoPause = false; + }; + typingIndicator = { + enable = true; + includeBlockedUsers = true; + }; + typingTweaks.enable = true; + unindent.enable = true; + unlockedAvatarZoom.enable = true; + userVoiceShow.enable = true; + validReply.enable = true; + validUser.enable = true; + vencordToolbox.enable = true; + viewIcons = { + enable = true; + format = "png"; + }; + voiceDownload.enable = true; + voiceMessages.enable = true; + volumeBooster.enable = true; + webScreenShareFixes.enable = true; + whoReacted.enable = true; + youtubeAdblock.enable = true; + }; + }; + quickCss = builtins.readFile ./theme.css; + }; +} diff --git a/home/programs/spicetify.nix b/home/programs/spicetify.nix new file mode 100644 index 0000000..a581bd6 --- /dev/null +++ b/home/programs/spicetify.nix @@ -0,0 +1,22 @@ +{ config, pkgs, inputs, ... }: + +let + spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.stdenv.hostPlatform.system}; +in { + imports = [ + inputs.spicetify-nix.homeManagerModules.spicetify + ]; + + programs.spicetify = { + enable = true; + + enabledExtensions = with spicePkgs.extensions; [ + adblockify + hidePodcasts + ]; + +# theme = spicePkgs.themes.onepunch; + theme = spicePkgs.themes.catppuccin; + colorScheme = "mocha"; + }; +} diff --git a/home/shells/fish.nix b/home/shells/fish.nix new file mode 100644 index 0000000..9634249 --- /dev/null +++ b/home/shells/fish.nix @@ -0,0 +1,17 @@ +{ ... }: + +{ + programs.fish = { + enable = true; + + interactiveShellInit = + '' + set fish_greeting + fastfetch + ''; + + shellAliases = { + gs = "git status"; + }; + }; +} diff --git a/home/shells/starship.nix b/home/shells/starship.nix new file mode 100644 index 0000000..bd4aa3c --- /dev/null +++ b/home/shells/starship.nix @@ -0,0 +1,10 @@ +{ ... }: +{ + programs.starship = { + enable = true; + + settings = { + add_newline = true; + }; + }; +} diff --git a/home/stylix.nix b/home/stylix.nix new file mode 100644 index 0000000..16830cc --- /dev/null +++ b/home/stylix.nix @@ -0,0 +1,8 @@ +{ inputs, ... }: +{ + imports = [ inputs.stylix.homeModules.stylix ]; + + stylix = { + enable = true; + }; +} diff --git a/home/terminals/foot.nix b/home/terminals/foot.nix new file mode 100644 index 0000000..5c3098b --- /dev/null +++ b/home/terminals/foot.nix @@ -0,0 +1,25 @@ +{pkgs, ...}: +let + footTheme = pkgs.fetchurl { + url = "https://codeberg.org/dnkl/foot/raw/branch/master/themes/gruvbox-dark"; + sha256 = "sha256-ubvnLgDEPGvNrwQdZRNguftg2SF5qcO1iVK0Tb5ZveI="; + }; +in +{ + programs.foot = { + enable = true; + settings = { + main = { + font="JetBrainsMonoNFM-Regular:size=14"; +# font-bold = "${font}:style=Bold:${withSize}"; +# font-italic = "${fontItalic}:style=Italic:${withSize}"; +# font-bold-italic = "${fontItalic}:style=BoldItalic:${withSize}"; + box-drawings-uses-font-glyphs = true; + include = "${footTheme}"; +}; + scrollback = { + lines = 10000; + }; + }; + }; + } diff --git a/home/wayland/eww.nix b/home/wayland/eww.nix new file mode 100644 index 0000000..fe7df23 --- /dev/null +++ b/home/wayland/eww.nix @@ -0,0 +1,7 @@ +{ ... }: +{ + programs.eww = { + enable = true; + enableFishIntegration = true; + }; +} diff --git a/home/wayland/hyprland/binds.nix b/home/wayland/hyprland/binds.nix new file mode 100644 index 0000000..8dc9ec8 --- /dev/null +++ b/home/wayland/hyprland/binds.nix @@ -0,0 +1,65 @@ +let + workspaces = builtins.concatLists (builtins.genList ( + x: let + ws = let + c = (x + 1) / 10; + in + builtins.toString (x + 1 - (c * 10)); + in [ + "$mod, ${ws}, workspace, ${toString (x + 1)}" + "$mod SHIFT, ${ws}, movetoworkspacesilent, ${toString (x + 1)}" + ] + ) + 5); +in { + wayland.windowManager.hyprland.settings = { + bindm = [ + "$mod, mouse:272, movewindow" + "$mod, mouse:273, resizewindow" + ]; + + bind = + [ + "$mod, RETURN, exec, foot" + "$mod, D, exec, wofi -f --show=drun --lines=5" +# --prompt=\"\"" + "$mod SHIFT, D, exec, grimblast --freeze copy area" +# "$mod SHIFT, F, exec, grimblast copysave output ~/.screenshots/$(date +'%s_hypr.png')" +# "$mod SHIFT, G, exec, grimblast copy active" +# "$mod CTRL, P, exec, swayidle timeout 2 'sleep 1; hyprctl dispatcher dpms off' resume 'hyprctl dispatcher dpms on & pkill swayidle'" + + "$mod SHIFT, Q, killactive," + "$mod CTRL, E, exit," + "$mod, SPACE, togglesplit," + "$mod, F, fullscreen," + "$mod, V, togglefloating," + "$mod, P, pseudo," + + "$mod, H, movefocus, l" + "$mod, L, movefocus, r" + "$mod, K, movefocus, u" + "$mod, J, movefocus, d" + + "$mod SHIFT, H, movewindow, l" + "$mod SHIFT, L, movewindow, r" + "$mod SHIFT, K, movewindow, u" + "$mod SHIFT, J, movewindow, d" + + "$mod SUPER, H, resizeactive, -10 0" + "$mod SUPER, L, resizeactive, 10 0" + "$mod SUPER, K, resizeactive, 0 -10" + "$mod SUPER, J, resizeactive, 0 10" + +# "$mod, E, togglegroup" +# "$mod SHIFT, E, lockactivegroup, toggle" +# "$mod, TAB, changegroupactive, f" +# "$mod SHIFT, TAB, changegroupactive, b" +# "$mod CTRL, L, moveoutofgroup, r" +# "$mod CTRL, H, moveoutofgroup, l" + +# "$mod, Prior, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+" +# "$mod, Next, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-" + ] + ++ workspaces; + }; +} diff --git a/home/wayland/waybar.nix b/home/wayland/waybar.nix new file mode 100644 index 0000000..ea0ccb4 --- /dev/null +++ b/home/wayland/waybar.nix @@ -0,0 +1,211 @@ +{config, ...}: { + programs.waybar = { + enable = true; + settings = { + mainBar = { + layer = "top"; + position = "top"; +# margin-top = 8; +# margin-bottom = 80; +# margin-left = 8; + reload_style_on_change = true; + modules-left = ["hyprland/workspaces"]; + modules-center = ["clock#date" "clock#time"]; + modules-right = ["pulseaudio/slider" "pulseaudio#percentage"]; + "hyprland/workspaces" = { + on-click = "activate"; + format = "{icon}"; + format-icons = { + "1" = "1"; + "2" = "2"; + "3" = "3"; + "4" = "4"; + "5" = "5"; + }; + persistent-workspaces = { + "*" = 5; + }; + }; + "clock#date" = { + format = "{:%a %B %d}"; + tooltip-format = "{:%Y %B}\n{calendar}"; +# rotate = 270; + }; + "clock#time" = { + format = "{:%I:%M}"; + }; + "pulseaudio" = { + format = "{icon}"; + format-bluetooth = "{icon}"; + format-muted = ""; + format-icons = { + headphones = ""; + default = [""]; + }; + scroll-step = 1; + on-click = "pavucontrol"; + }; + "pulseaudio#percentage" = { + on-click = "pactl set-sink-mute @DEFAULT_SINK@ toggle"; + format = "{volume}%"; + }; + "pulseaudio/slider" = { + min = 0; + max = 100; + orientation = "vertical"; + }; + }; + }; + /* + style = '' + @define-color mainbg #${config.colorScheme.palette.base00}; + @define-color modulesbg #${config.colorScheme.palette.base01}; + @define-color text #${config.colorScheme.palette.base05}; + @define-color alttext1 #${config.colorScheme.palette.base0C}; + @define-color alttext2 #${config.colorScheme.palette.base05}; + @define-color border #${config.colorScheme.palette.base0E}; + @define-color empty #${config.colorScheme.palette.base02}; + @define-color persistent #${config.colorScheme.palette.base04}; + @define-color hover #${config.colorScheme.palette.base09}; + @define-color white #${config.colorScheme.palette.base05}; + @define-color red #${config.colorScheme.palette.base08}; + @define-color orange #${config.colorScheme.palette.base09}; + @define-color yellow #${config.colorScheme.palette.base0A}; + @define-color green #${config.colorScheme.palette.base0B}; + + * { + all: initial; + font-family:'JetBrainsMono Nerd Font'; + padding-left: 1px; + padding-right: 1px; + } + + window#waybar { + background: @mainbg; + border: 1px solid @border; + border-radius: 5px; + } + + tooltip { + background: #${config.colorScheme.palette.base03}; + border: 2px solid #${config.colorScheme.palette.base0C}; + border-radius: 5px; + font-size: 12pt; + } + + tooltip label { + padding: 10px; + } + + #workspaces { + margin: 10px 0px; + background: @modulesbg; + font-size: 12pt; + padding: 20px 0px; + border-top:3px solid @border; + border-top-left-radius: 50px; + border-top-right-radius: 5px; + border-bottom: 3px solid @border; + border-bottom-right-radius: 50px; + border-bottom-left-radius: 5px; + } + + #workspaces button { + font-size: 18pt; + padding: 2px; + margin: 5px 6px; + border-radius: 10px; + } + + #workspaces button.persistent { + background-color: @persistent; + } + + #workspaces button.empty { + background-color: @empty; + } + + #workspaces button.visible { + background-color: @empty; + } + + #workspaces button.active { + background-color: @green; + } + + #workspaces button.urgent { + background-color: @red; + } + + #workspaces button:hover { + background-color: @hover; + } + + #pulseaudio, #clock, #clock.date, #clock.time { + background: @modulesbg; + } + + #pulseaudio { + padding: 1px 5px 1px 5px; + color: @text; + font-size: 16px; + } + + #clock.date { + padding: 30px 5px 10px 5px; + font-size: 14px; + color: @alttext2; + border-top:3px solid @border; + border-top-left-radius: 50px; + border-top-right-radius: 5px; + } + + #clock.time { + padding: 10px 5px 30px 5px; + font-size: 14px; + color: @alttext1; + border-bottom: 3px solid @border; + border-bottom-left-radius: 5px; + border-bottom-right-radius: 50px; + } + + #pulseaudio-slider, #pulseaudio.percentage { + background-color: @modulesbg; + } + + #pulseaudio-slider { + padding: 15px 0px 5px 0px; + border-top: 3px solid @border; + border-top-left-radius: 50px; + border-top-right-radius: 5px; + } + #pulseaudio-slider slider { + min-height: 0px; + min-width: 1px; + opacity: 0; + background-image: none; + border: none; + box-shadow: none; + } + #pulseaudio-slider trough { + min-height: 70px; + min-width: 0px; + border-radius: 5px; + background-color: @border; + } + #pulseaudio-slider highlight { + min-width: 10px; + border-radius: 5px; + background-color: @white; + } + + #pulseaudio.percentage { + font-size: 12px; + margin: 0px 0px; + padding: 2px 5px; + color: @text; + } + ''; + */ + }; +} diff --git a/home/wayland/xdg.nix b/home/wayland/xdg.nix new file mode 100644 index 0000000..f4b1294 --- /dev/null +++ b/home/wayland/xdg.nix @@ -0,0 +1,37 @@ +{ ... }: + +{ + xdg.userDirs = { + enable = true; + + createDirectories = true; + download = "$HOME/dl"; + documents = "$HOME/docs"; + pictures = "/media/pics"; + videos = "/media/vids"; + + desktop = null; + music = null; + publicShare = null; + templates = null; + + extraConfig = { + XDG_PROJECTS_DIR = "$HOME/projects"; + XDG_GAMES_DIR = "$HOME/Games"; + XDG_MEDIA_DIR = "/media"; + XDG_SS_DIR = "/media/ss"; + XDG_CLIPS_DIR = "/media/clips"; + XDG_ISO_DIR = "/media/iso"; + XDG_ARCHIVE_DIR = "/media/archive"; + }; + }; + home.sessionVariables = { + XDG_PROJECTS_DIR = "$HOME/projects"; + XDG_GAMES_DIR = "$HOME/Games"; + XDG_MEDIA_DIR = "/media"; + XDG_SS_DIR = "/media/ss"; + XDG_CLIPS_DIR = "/media/clips"; + XDG_ISO_DIR = "/media/iso"; + XDG_ARCHIVE_DIR = "/media/archive"; + }; +} -- cgit v1.3