{ config, lib, pkgs, pkgs-unstable, inputs, self, ... }: let noctalia-package = inputs.noctalia.packages.${pkgs.stdenv.hostPlatform.system}.default.override { calendarSupport = true; }; ns = lib.getExe noctalia-package; ns-ipc = args: [ ns "ipc" "call" ] ++ args; in { imports = [ ../gnome ./dnote.nix ../modules/zed ../modules/voxtype ../modules/elephant ./secrets.nix inputs.hastebin.nixosModules.hm inputs.agenix.homeManagerModules.default inputs.voxtype.homeManagerModules.default inputs.noctalia.homeModules.default inputs.niri-flake.homeModules.niri inputs.nix-flatpak.homeManagerModules.nix-flatpak ]; # This value determines the Home Manager release that your configuration is # compatible with. This helps avoid breakage when a new Home Manager release # introduces backwards incompatible changes. # # You should not change this value, even if you update Home Manager. If you do # want to update the value, then make sure to first check the Home Manager # release notes. home.stateVersion = "23.11"; # Please read the comment before changing. home.packages = with pkgs; [ htop gnupg pkgs-unstable.yubioath-flutter pkgs-unstable.yubikey-manager gcc sqlite noto-fonts noto-fonts-cjk-sans noto-fonts-color-emoji source-sans-pro mosh docker-compose (signal-desktop.override { commandLineArgs = "--password-store=gnome-libsecret"; }) cargo blanket wl-clipboard gnumeric gh neovim-remote pkgs-unstable.gradia crystal shards moreutils keymapp gnumake tig jq yt-dlp ffmpeg otp manix (writeShellScriptBin "fd" '' ${fd}/bin/fd -H "$@" '') pkgs-unstable.rpi-imager picocom imagemagick ghostscript inkscape jless scribus dnscontrol protonmail-bridge hydroxide imapsync nixfmt-rfc-style tree virt-manager pkgs-unstable.ncspot pkgs-unstable.devbox pkgs-unstable.feishin openscad pkgs-unstable.shairport-sync-airplay2 (writeShellScriptBin "pw" '' ${lib.getExe rbw} ls --fields 'id,folder,name' | \ ${lib.getExe gawk} -F '\t' '{print $1 "\t" ($2 == "" ? "" : $2 "/") $3}' | \ ${lib.getExe config.services.walker.package} -d -l 2 | \ xargs ${lib.getExe rbw} get "$@" | ${lib.getExe' wl-clipboard "wl-copy"} '') (google-fonts.override { fonts = [ "Tajawal" ]; }) pkgs-unstable.opencode (writeShellScriptBin "nr" '' ${lib.getExe nix} run "nixpkgs#''${1}" "$@" '') blueman pavucontrol (writeShellScriptBin "voxtoggle" '' status=$(${lib.getExe config.programs.voxtype.package} status) pid=$(cat ''${XDG_RUNTIME_DIR}/voxtype/pid) if [[ "$status" == "stopped" ]]; then exit 1 elif [[ "$status" == "recording" ]]; then kill -SIGUSR2 "$pid" else kill -SIGUSR1 "$pid" fi '') (writeShellScriptBin "scrot" '' set -eo pipefail ${lib.getExe grim} -t ppm -g "$(${lib.getExe slurp} -o -d -F monospace)" - | ${lib.getExe gradia} '') inputs.tree_hugger.packages.${stdenv.hostPlatform.system}.default (writeShellScriptBin "ns" "${lib.join " " (ns-ipc [ ''"$@"'' ])}") ]; programs = { noctalia-shell = { enable = true; settings = { bar = { density = "compact"; position = "top"; showCapsule = false; widgets = { left = [ { id = "Workspace"; hideUnoccupied = true; labelMode = "none"; } ]; center = [ { id = "Clock"; formatHorizontal = "HH:mm"; formatVertical = "HH mm"; usePrimaryColor = true; } ]; right = [ { id = "plugin:privacy-indicator"; } { id = "Battery"; warningThreshold = 20; } { id = "NotificationHistory"; } { id = "Network"; } { id = "Bluetooth"; } { id = "VPN"; } { id = "ControlCenter"; useDistroLogo = true; } ]; }; }; audio.visualizerType = "linear"; wallpaper = { overviewEnabled = true; directory = "~/Pictures/Wallpapers"; automationEnabled = true; }; controlCenter.shortcuts = { right = [ { id = "PowerProfile"; } { id = "KeepAwake"; } { id = "NightLight"; } { id = "DarkMode"; } ]; }; sessionMenu = { countdownDuration = 5000; powerOptions = let powerOption = action: options: { inherit action; enabled = true; } // options; in [ (powerOption "lock" { keybind = "1"; countdownEnabled = false; }) (powerOption "suspend" { keybind = "2"; countdownEnabled = false; }) (powerOption "hibernate" { keybind = "3"; }) (powerOption "reboot" { keybind = "4"; }) (powerOption "logout" { keybind = "5"; }) (powerOption "shutdown" { keybind = "6"; }) (powerOption "rebootToUefi" { keybind = "7"; }) ]; }; colorSchemes.useWallpaperColors = true; nightLight.enabled = true; idle.enabled = true; general = { avatarImage = "~/.face"; radiusRatio = 0.2; clockStyle = "analog"; }; location = { monthBeforeDay = false; analogClockInCalendar = true; firstDayOfWeek = 0; showWeekNumberInCalendar = true; autoLocate = true; }; package = noctalia-package; }; }; nh = { enable = true; flake = self; }; dnote.enable = true; home-manager.enable = true; bat = { enable = true; extraPackages = with pkgs.bat-extras; [ batdiff batwatch ]; config = { pager = "less -FR"; }; }; direnv = { enable = true; nix-direnv.enable = true; enableZshIntegration = true; }; mpv = { enable = true; config = { hwdec = "auto-safe"; vo = "gpu"; profile = "gpu-hq"; gpu-context = "wayland"; }; }; kitty = { enable = true; font = { name = "IosevkaTerm NFM"; size = 14; }; shellIntegration.enableZshIntegration = true; themeFile = "Tomorrow_Night"; settings = { hide_window_decorations = true; enabled_layouts = "splits,stack"; }; keybindings = { "kitty_mod+q" = ""; "kitty_mod+w" = ""; "kitty_mod+t" = "new_tab_with_cwd"; "kitty_mod+tab" = "next_tab"; "kitty_mod+enter" = "launch --location=hsplit --cwd=current"; "kitty_mod+space" = "launch --location=vsplit --cwd=current"; "kitty_mod+h" = "neighboring_window left"; "kitty_mod+l" = "neighboring_window right"; "kitty_mod+k" = "neighboring_window up"; "kitty_mod+j" = "neighboring_window down"; "kitty_mod+1" = "goto_tab 1"; "kitty_mod+2" = "goto_tab 2"; "kitty_mod+3" = "goto_tab 3"; "kitty_mod+4" = "goto_tab 4"; "kitty_mod+5" = "goto_tab 5"; "kitty_mod+6" = "goto_tab 6"; "kitty_mod+7" = "goto_tab 7"; "kitty_mod+8" = "goto_tab 8"; "kitty_mod+9" = "goto_tab 9"; "kitty_mod+0" = "goto_tab 10"; "kitty_mod+f" = "toggle_layout stack"; "kitty_mod+/" = "show_scrollback"; "ctrl+alt+h" = "move_window left"; "ctrl+alt+l" = "move_window right"; "ctrl+alt+k" = "move_window up"; "ctrl+alt+j" = "move_window down"; "ctrl+alt+enter" = "layout_action rotate"; }; }; vivaldi.enable = true; git = { enable = true; settings = { alias = { st = "status"; co = "checkout"; b = "branch"; }; pull = { rebase = "true"; }; push = { autoSetupRemote = true; }; init = { defaultBranch = "main"; }; user = { name = "Joakim Repomaa"; signingKey = "F0AF1CE34733B22317A8937D05557F53CD3C6458"; }; commit.gpgSign = true; }; }; gpg = { enable = true; }; zsh = { enable = true; enableVteIntegration = true; cdpath = [ "${config.xdg.configHome}/home-manager" ]; defaultKeymap = "viins"; dirHashes = { hm = "${config.xdg.configHome}/home-manager"; }; history = { path = "${config.home.homeDirectory}/.cache/zsh/history"; save = 100000; size = 100000; }; initContent = '' . "${config.xdg.configHome}/zsh/init" . "${config.age.secrets.context7.path}" ''; }; lazygit = let getBaseBranch = pkgs.writeShellScriptBin "git-base-branch" '' current_branch="$(git rev-parse --abbrev-ref HEAD)" if [[ "$current_branch" =~ -review$ ]]; then echo "''${current_branch%-review}" else git config get init.defaultBranch fi ''; escapeGoTemplate = builtins.replaceStrings [ "{{" "}}" ] [ ''{{"{{"}}'' ''{{"}}"}}'' ]; in { enable = true; settings = { gui = { nerdFontsVersion = "3"; }; git = { showUntrackedFiles = "all"; branchLogCmd = "git log {{branchName}} --first-parent --color=always --pretty=format:'%Cgreen%h%Creset %Cblue%aN%Creset %C(cyan)%<(14)%ar%Creset %s' --abbrev-commit"; overrideGpg = true; }; os = { edit = "\${EDITOR} -- {{filename}}"; editAtLine = "\${EDITOR} -- {{filename}}:{{line}}"; editAtLineAndWait = "\${EDITOR} --wait -- {{filename}}:{{line}}"; openDirInEditor = "\${EDITOR} -- {{dir}}"; }; promptToReturnFromSubprocess = false; keybinding = { universal = { nextItem = ""; prevItem = ""; }; commits = { moveDownCommit = ""; moveUpCommit = ""; }; }; customCommands = [ { key = ""; context = "global"; command = '' git push --force-with-lease --set-upstream origin "{{.SelectedLocalBranch.Name}}" && gh pr create --title "{{.SelectedLocalBranch.Name}}" -B "$(${lib.getExe getBaseBranch})" --fill || (git log --reverse --no-merges --pretty='- %s' master..HEAD | gh pr edit --body-file -); gh pr view --web ''; } { key = "N"; context = "localBranches"; prompts = [ { type = "input"; title = "New Branch Name:"; key = "BranchName"; initialValue = "{{.SelectedLocalBranch.Name}}-review"; } ]; command = '' git checkout -b {{.Form.BranchName | quote}} ''; } { key = "G"; context = "localBranches"; prompts = [ { type = "menuFromCommand"; title = "PR:"; key = "pr"; command = escapeGoTemplate "gh pr list --search '-author:@me' --json number,title,author,updatedAt -t '{{range .}}{{tablerow .number .title .author.login}}{{end}}'"; filter = "(?[0-9]+)(?.*)"; labelFormat = "{{ .rest }}"; valueFormat = "{{ .pr_number }}"; } ]; command = '' gh pr checkout {{.Form.pr | quote}} ''; } ]; }; }; obs-studio.enable = true; ssh = { enable = true; enableDefaultConfig = false; matchBlocks = { "*" = { controlMaster = "auto"; controlPath = "${config.home.homeDirectory}/.ssh/masters-control/%r@%h:%p"; controlPersist = "1h"; forwardAgent = false; addKeysToAgent = "no"; compression = false; serverAliveInterval = 0; serverAliveCountMax = 3; hashKnownHosts = false; userKnownHostsFile = "${config.home.homeDirectory}/.ssh/known_hosts"; setEnv = { TERM = "screen-256color"; }; }; "apu" = { user = "root"; }; }; }; spotify-player = { enable = true; settings = { enable_streaming = "Always"; theme = "tomorrow_night"; copy_command = "wl-copy"; }; themes = [ { name = "tomorrow_night"; palette = { background = "#1d1f21"; foreground = "#c5c8c6"; black = "#000000"; red = "#cc6666"; green = "#b5bd68"; yellow = "#f0c674"; blue = "#81a2be"; magenta = "#b294bb"; cyan = "#8abeb7"; white = "#ffffff"; bright_black = "#000000"; bright_red = "#cc6666"; bright_green = "#b5bd68"; bright_yellow = "#f0c674"; bright_blue = "#81a2be"; bright_magenta = "#b294bb"; bright_cyan = "#8abeb7"; bright_white = "#ffffff"; }; component_style = { playback_metadata = { fg = "#8abeb7"; }; playback_progress_bar = { bg = "#1d1f21"; fg = "#c5c8c6"; }; }; } ]; }; neovide = { enable = true; settings = { font = { normal = [ "IosevkaTerm NFM" ]; size = 12.0; }; fork = true; }; }; hastebin = { enable = true; settings = { host = "https://bin.freun.dev"; auth_token_file = "${config.xdg.configHome}/hastebin/auth_token"; clipboard_command = "${pkgs.wl-copy-both}/bin/wl-copy"; default_renderers = let code = [ "js" "ts" "jsx" "tsx" "rs" "nix" "cr" "ecr" "rb" "erb" "yaml" "yml" "json" "toml" "html" "xml" "css" "scss" "sass" "less" "sql" "sh" ]; in lib.listToAttrs ( lib.map (name: { inherit name; value = "hl"; }) code ); }; }; zed-editor = { enable = true; defaultEditor = true; }; voxtype = { enable = true; package = inputs.voxtype.packages.${pkgs.stdenv.hostPlatform.system}.vulkan; model.name = "large-v3-turbo"; service.enable = true; settings = { hotkey.enabled = false; whisper.language = "auto"; output.notification = { on_recording_start = false; on_recording_stop = false; on_transcription = false; }; }; postProcessing = { enable = true; settings = { model = "qwen3:4b-instruct"; commonInstructions = "no quotes, no emojis, no explanations"; prompts = [ { title = "Clean up"; instructions = "First identify what language this is, then respond in that language. Clean up: remove filler words, fix grammar and punctuation. Preserve all nuances of the original dictation. Output ONLY the cleaned text"; } { title = "Make a title"; instructions = "First identify what language this is, then respond in that language. Create a concise and descriptive title"; } { title = "Summarize"; instructions = "First identify what language this is, then respond in that language. Summarize in a few sentences"; } { title = "Commit message"; instructions = "Write a concise and descriptive git commit message for this dictation in English"; } { title = "Translate to English"; instructions = "Translate this dictation. Remove filler words, fix grammar and punctuation. Output ONLY the translation"; } ]; }; }; }; }; gnome = { keyboard.sources = [ "us+altgr-intl" ]; keybindings = { builtin = { screenshot-window = [ ]; show-screenshot-ui = [ ]; }; custom = [ { binding = "Print"; command = "gradia --screenshot"; name = "Gradia"; } { binding = "Print"; command = "kooha"; name = "Kooha"; } ]; }; power = { powerButton = "hibernate"; }; extensions = { paperwm = { enable = true; winprops = [ { wm_class = "vivaldi-stable"; preferredWidth = "67%"; } { wm_class = "yubioath-flutter"; scratch_layer = true; } { wm_class = "signal"; scratch_layer = true; } { wm_class = "Slack"; scratch_layer = true; } { wm_class = "Supersonic"; scratch_layer = true; } { wm_class = "io.github.seadve.Kooha"; scratch_layer = true; } { wm_class = "/.*/"; preferredWidth = "33"; } ]; keybindings = { move-down = [ "Down" "j" ]; move-left = [ "Left" "h" ]; move-right = [ "Right" "l" ]; move-up = [ "Up" "k" ]; switch-down = [ "Down" "j" ]; switch-left = [ "Left" "h" ]; switch-right = [ "Right" "l" ]; switch-up = [ "Up" "k" ]; }; }; freon = { enable = true; }; }; nightLight.enable = true; }; fonts.fontconfig = { enable = true; defaultFonts = { emoji = [ "Noto Color Emoji" ]; monospace = [ "IosevkaTerm NFM" ]; sansSerif = [ "Source Sans Pro" ]; }; }; targets.genericLinux.enable = true; xdg.mime.enable = true; xdg = { enable = true; configFile = { tmux.source = dotfiles/tmux; zsh.source = dotfiles/zsh; "fd/ignore".text = '' /.git/ ''; "vivaldi/NativeMessagingHosts/ff2mpv.json".text = builtins.toJSON { name = "ff2mpv"; description = "ff2mpv's external manifest"; path = "${pkgs.ff2mpv-rust}/bin/ff2mpv-rust"; type = "stdio"; allowed_origins = [ "chrome-extension://ephjcajbkgplkjmelpglennepbpmdpjg/" ]; }; }; }; # Home Manager can also manage your environment variables through # 'home.sessionVariables'. If you don't want to manage your shell through Home # Manager then you have to manually source 'hm-session-vars.sh' located at # either # # ~/.nix-profile/etc/profile.d/hm-session-vars.sh # # or # # ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh # # or # # /etc/profiles/per-user/jokke/etc/profile.d/hm-session-vars.sh # home.sessionVariables = { NIXOS_OZONE_WL = 1; NVIM_LISTEN_ADDRESS = "$XDG_RUNTIME_DIR/nvimsocket"; PAGER = "bat --paging=always --style=plain"; MANPAGER = "sh -c 'col -bx | bat -l man -p'"; MANROFFOPT = "-c"; DO_NOT_TRACK = 1; }; systemd.user.sessionVariables = lib.mapAttrs (_: v: toString v) config.home.sessionVariables; programs.zsh.sessionVariables = config.home.sessionVariables; home.shellAliases = { _ = "sudo"; icr = "crystal i"; hm = "home-manager"; chat = "ssh root@ipv4.jokke.space pkill mosh; mosh weechat@ipv4.jokke.space"; wget = " wget --content-disposition"; pj = "jq | bat -l json"; ls = "ls --color=auto"; }; services = { gpg-agent = with pkgs; { enable = true; enableSshSupport = true; pinentry.package = pinentry-gnome3; }; }; services.flatpak = { update.onActivation = true; packages = [ "dev.diegovsky.Riff" ]; }; services.walker = { enable = true; package = pkgs.symlinkJoin { inherit (pkgs-unstable.walker) name meta; paths = [ pkgs-unstable.walker ]; nativeBuildInputs = [ pkgs.makeBinaryWrapper ]; postBuild = '' wrapProgram $out/bin/walker \ --prefix PATH : ${lib.makeBinPath [ config.services.elephant.package ]} ''; }; systemd = { enable = true; }; settings = { providers = { default = [ "desktopapplications" "calc" "websearch" "bitwarden" ]; }; }; }; services.elephant.enable = true; systemd.user.services.walker.Install.WantedBy = lib.mkForce [ "graphical-session.target" ]; systemd.user.services.shairport-sync = { Unit = { Description = "AirPlay audio server"; After = [ "pipewire-pulse.service" "network.target" ]; }; Service = { ExecStart = "${lib.getExe pkgs-unstable.shairport-sync-airplay2} -- pw"; Restart = "on-failure"; }; Install = { WantedBy = [ "graphical-session.target" ]; }; }; programs.gpg.scdaemonSettings = { disable-ccid = true; }; programs.rbw.enable = true; programs.rclone.enable = true; programs.firefox.enable = true; xdg.configFile."opencode/opencode.jsonc".text = builtins.toJSON { "$schema" = "https://opencode.ai/config.json"; model = "firepass/accounts/fireworks/routers/kimi-k2p6-turbo"; small_model = "firepass/accounts/fireworks/routers/kimi-k2p6-turbo"; agent = { explore.model = "firepass/accounts/fireworks/routers/kimi-k2p6-turbo"; }; theme = "system"; lsp = { ruby-lsp = { initialization = { enabledFeatures = { codeActions = true; codeLens = true; completion = true; definition = true; diagnostics = true; documentHighlights = true; documentLink = true; documentSymbols = true; foldingRanges = true; formatting = false; hover = true; inlayHint = true; onTypeFormatting = true; selectionRanges = true; semanticHighlighting = true; signatureHelp = true; typeHierarchy = true; workspaceSymbol = true; }; linters = [ "standard" ]; }; extensions = [ ".rb" ".erb" ".haml" ]; command = [ "bundle" "exec" "ruby-lsp" ]; }; rubocop = { command = [ "bundle" "exec" "rubocop" "--lsp" ]; extensions = [ ".rb" ".erb" ".haml" ]; }; nil = { command = [ (lib.getExe pkgs.nil) ]; extensions = [ ".nix" ]; }; ameba-ls = { command = [ (lib.getExe pkgs-unstable.ameba-ls) ]; extensions = [ ".cr" ]; }; }; mcp = { context7 = { type = "remote"; url = "https://mcp.context7.com/mcp"; headers = { CONTEXT7_API_KEY = "{env:CONTEXT7_API_KEY}"; }; enabled = true; }; }; }; programs.niri = let bind = { modifiers, key, action, args ? [ ], }: { ${lib.join "+" (modifiers ++ [ key ])}.action.${action} = args; }; in { enable = true; package = pkgs-unstable.niri; settings = { input = { keyboard = { xkb = { layout = "us"; variant = "altgr-intl"; }; numlock = true; }; touchpad = { tap = true; dwt = true; dwtp = true; natural-scroll = true; }; focus-follows-mouse = { enable = true; max-scroll-amount = "10%"; }; }; outputs = { "eDP-1" = { scale = 1.5; }; "DP-5" = { scale = 1.0; }; "DP-3" = { scale = 1.2; }; }; layout = { gaps = 5; center-focused-column = "never"; preset-column-widths = [ { proportion = 1.0 / 3.0; } { proportion = 1.0 / 2.0; } { proportion = 2.0 / 3.0; } ]; default-column-width = { proportion = 1.0 / 2.0; }; focus-ring = { enable = true; width = 4; active.color = "#7fc8ff"; inactive.color = "#505050"; }; border = { enable = false; width = 4; active.color = "#ffc87f"; inactive.color = "#505050"; urgent.color = "#9b0000"; }; shadow = { enable = true; softness = 30; spread = 5; offset = { x = 0; y = 5; }; color = "#0007"; }; }; spawn-at-startup = [ { argv = [ ns ]; } ]; hotkey-overlay.skip-at-startup = true; screenshot-path = "~/Pictures/Screenshots/Screenshot from %Y-%m-%d %H-%M-%S.png"; debug.honor-xdg-activation-with-invalid-serial = true; layer-rules = [ { matches = [ { namespace = "^noctalia-overview*"; } ]; place-within-backdrop = true; } ]; window-rules = [ { matches = [ { app-id = "firefox$"; title = "^Picture-in-Picture$"; } ]; open-floating = true; } { geometry-corner-radius = { top-left = 14.; top-right = 14.; bottom-left = 14.; bottom-right = 14.; }; clip-to-geometry = true; } #{ # background-effect = { # blur = true; # xray = false; # }; #} ]; binds = lib.foldl' (acc: x: acc // x) { } ( [ { "Mod+Shift+Slash" = { action.show-hotkey-overlay = [ ]; }; "Mod+Return" = { hotkey-overlay.title = "Open a Terminal: kitty"; action.spawn = "kitty"; }; "Mod+Z" = { hotkey-overlay.title = "Open a launcher: walker"; action.spawn = "walker"; }; "Mod+Space" = { action.spawn = "voxtoggle"; }; "Mod+Alt+L" = { hotkey-overlay.title = "Lock the Screen: hyprlock"; action.spawn = ns-ipc [ "lockScreen" "lock" ]; }; "XF86AudioRaiseVolume" = { allow-when-locked = true; action.spawn = ns-ipc [ "volume" "increase" ]; }; "XF86AudioLowerVolume" = { allow-when-locked = true; action.spawn = ns-ipc [ "volume" "decrease" ]; }; "XF86AudioMute" = { allow-when-locked = true; action.spawn = ns-ipc [ "volume" "muteOutput" ]; }; "XF86AudioMicMute" = { allow-when-locked = true; action.spawn = ns-ipc [ "volume" "muteInput" ]; }; "XF86AudioPlay" = { allow-when-locked = true; action.spawn = ns-ipc [ "media" "playPause" ]; }; "XF86AudioPrev" = { allow-when-locked = true; action.spawn = ns-ipc [ "media" "previous" ]; }; "XF86AudioNext" = { allow-when-locked = true; action.spawn = ns-ipc [ "media" "next" ]; }; "XF86MonBrightnessUp" = { allow-when-locked = true; action.spawn = ns-ipc [ "brightness" "increase" ]; }; "XF86MonBrightnessDown" = { allow-when-locked = true; action.spawn = ns-ipc [ "brightness" "decrease" ]; }; "Mod+O" = { repeat = false; action.toggle-overview = [ ]; }; "Mod+Backspace" = { repeat = false; action.close-window = [ ]; }; "Mod+BracketLeft".action.consume-or-expel-window-left = [ ]; "Mod+BracketRight".action.consume-or-expel-window-right = [ ]; "Mod+Comma".action.consume-window-into-column = [ ]; "Mod+Period".action.expel-window-from-column = [ ]; "Mod+R".action.switch-preset-column-width = [ ]; "Mod+Ctrl+R".action.switch-preset-window-height = [ ]; "Mod+Shift+R".action.reset-window-height = [ ]; "Mod+F".action.maximize-column = [ ]; "Mod+Shift+F".action.fullscreen-window = [ ]; "Mod+M".action.maximize-window-to-edges = [ ]; "Mod+Ctrl+F".action.expand-column-to-available-width = [ ]; "Mod+C".action.center-column = [ ]; "Mod+Ctrl+C".action.center-visible-columns = [ ]; "Mod+Minus".action.set-column-width = "-10%"; "Mod+Equal".action.set-column-width = "+10%"; "Mod+Shift+Minus".action.set-window-height = "-10%"; "Mod+Shift+Equal".action.set-window-height = "+10%"; "Mod+V".action.toggle-window-floating = [ ]; "Mod+Shift+V".action.switch-focus-between-floating-and-tiling = [ ]; "Mod+W".action.toggle-column-tabbed-display = [ ]; "Print".action.spawn = "scrot"; "Mod+Escape" = { allow-inhibiting = true; action.toggle-keyboard-shortcuts-inhibit = [ ]; }; "Mod+Shift+E".action.quit = [ ]; "Ctrl+Alt+Delete".action.quit = [ ]; "Mod+Shift+P".action.power-off-monitors = [ ]; } ] ++ (map ( { dir, keys, }: (lib.mergeAttrsList ( map ( { modifiers, action }: (lib.mergeAttrsList (map (key: bind { inherit modifiers key action; }) keys)) ) [ { modifiers = [ "Mod" ]; action = "focus-column-${dir}"; } { modifiers = [ "Mod" "Shift" ]; action = "move-column-${dir}"; } { modifiers = [ "Mod" "Ctrl" ]; action = "focus-monitor-${dir}"; } { modifiers = [ "Mod" "Shift" "Ctrl" ]; action = "move-column-to-monitor-${dir}"; } ] )) ) [ { dir = "left"; keys = [ "Left" "H" ]; } { dir = "right"; keys = [ "Right" "L" ]; } ] ) ++ (map ( { dir, keys, }: (lib.mergeAttrsList ( map ( { modifiers, action }: (lib.mergeAttrsList (map (key: bind { inherit modifiers key action; }) keys)) ) [ { modifiers = [ "Mod" ]; action = "focus-window-or-workspace-${dir}"; } { modifiers = [ "Mod" "Shift" ]; action = "move-window-${dir}-or-to-workspace-${dir}"; } { modifiers = [ "Mod" "Ctrl" ]; action = "focus-monitor-${dir}"; } { modifiers = [ "Mod" "Shift" "Ctrl" ]; action = "move-column-to-monitor-${dir}"; } ] )) ) [ { dir = "up"; keys = [ "Up" "K" ]; } { dir = "down"; keys = [ "Down" "J" ]; } ] ) ++ [ { "Mod+Home".action.focus-column-first = [ ]; "Mod+End".action.focus-column-last = [ ]; "Mod+Shift+Home".action.move-column-to-first = [ ]; "Mod+Shift+End".action.move-column-to-last = [ ]; "Mod+Page_Down".action.focus-workspace-down = [ ]; "Mod+Page_Up".action.focus-workspace-up = [ ]; "Mod+U".action.focus-workspace-down = [ ]; "Mod+I".action.focus-workspace-up = [ ]; "Mod+Ctrl+Page_Down".action.move-column-to-workspace-down = [ ]; "Mod+Ctrl+Page_Up".action.move-column-to-workspace-up = [ ]; "Mod+Ctrl+U".action.move-column-to-workspace-down = [ ]; "Mod+Ctrl+I".action.move-column-to-workspace-up = [ ]; "Mod+Shift+Page_Down".action.move-workspace-down = [ ]; "Mod+Shift+Page_Up".action.move-workspace-up = [ ]; "Mod+Shift+U".action.move-workspace-down = [ ]; "Mod+Shift+I".action.move-workspace-up = [ ]; "Mod+WheelScrollDown" = { cooldown-ms = 150; action.focus-workspace-down = [ ]; }; "Mod+WheelScrollUp" = { cooldown-ms = 150; action.focus-workspace-up = [ ]; }; "Mod+Ctrl+WheelScrollDown" = { cooldown-ms = 150; action.move-column-to-workspace-down = [ ]; }; "Mod+Ctrl+WheelScrollUp" = { cooldown-ms = 150; action.move-column-to-workspace-up = [ ]; }; "Mod+WheelScrollRight".action.focus-column-right = [ ]; "Mod+WheelScrollLeft".action.focus-column-left = [ ]; "Mod+Ctrl+WheelScrollRight".action.move-column-right = [ ]; "Mod+Ctrl+WheelScrollLeft".action.move-column-left = [ ]; "Mod+Shift+WheelScrollDown".action.focus-column-right = [ ]; "Mod+Shift+WheelScrollUp".action.focus-column-left = [ ]; "Mod+Ctrl+Shift+WheelScrollDown".action.move-column-right = [ ]; "Mod+Ctrl+Shift+WheelScrollUp".action.move-column-left = [ ]; } ] ++ (map (number: { "Mod+${toString number}".action.focus-workspace = number; "Mod+Shift+${toString number}".action.move-column-to-workspace = number; }) (lib.range 1 9)) ); }; }; gnome.automaticTimeZone = true; gtk.enable = true; home.pointerCursor = { enable = true; name = "Adwaita"; package = pkgs.adwaita-icon-theme; gtk.enable = true; }; }