From 63badd58cf19fe6f4b823fee53a4d6f6c2187e74 Mon Sep 17 00:00:00 2001 From: tom barrett Date: Sun, 12 May 2024 14:16:27 +0200 Subject: screensaver --- configuration.nix | 22 +++++++++++++--------- home.nix | 10 +++------- xmonad.hs | 2 ++ 3 files changed, 18 insertions(+), 16 deletions(-) diff --git a/configuration.nix b/configuration.nix index dedcd96..28c5d7d 100644 --- a/configuration.nix +++ b/configuration.nix @@ -21,15 +21,19 @@ shell = pkgs.zsh; }; - programs.zsh = { - enable = true; - promptInit = '' - autoload -Uz vcs_info - precmd() { vcs_info } - zstyle ':vcs_info:git:*' formats '|%F{3}%b%f' - setopt PROMPT_SUBST - PROMPT='<%F{2}%n%f@%F{6}%m%f|%F{5}%~%f''${vcs_info_msg_0_}%f> ' - ''; + programs = { + slock.enable = true; + zsh = { + enable = true; + promptInit = '' + autoload -Uz vcs_info + precmd() { vcs_info } + zstyle ':vcs_info:git:*' formats '|%F{3}%b%f' + setopt PROMPT_SUBST + PROMPT='<%F{2}%n%f@%F{6}%m%f|%F{5}%~%f''${vcs_info_msg_0_}%f> ' + bindkey '^f' end-of-line + ''; + }; }; fonts.packages = [pkgs.hermit]; services = { diff --git a/home.nix b/home.nix index 6bbe0fb..4451d4d 100644 --- a/home.nix +++ b/home.nix @@ -19,8 +19,8 @@ in { stateVersion = "23.11"; packages = with pkgs; [ acpi - binutils bemenu + binutils feh file ghc @@ -32,6 +32,7 @@ in { tmux tree vim + xautolock xmobar ]; sessionVariables = @@ -147,6 +148,7 @@ in { userEmail = "tom@tombarrett.xyz"; extraConfig = { init.defaultBranch = "master"; + pull.rebase = true; }; }; gpg.enable = true; @@ -167,12 +169,6 @@ in { enableContribAndExtras = true; }; services = { - xscreensaver = { - enable = true; - settings = { - mode = "blank"; - }; - }; gpg-agent = { enable = true; enableSshSupport = true; diff --git a/xmonad.hs b/xmonad.hs index 63ce88b..483744b 100644 --- a/xmonad.hs +++ b/xmonad.hs @@ -68,6 +68,7 @@ main = , ("M-q", kill) , ("M-d", spawn $ "bemenu-run -p ' ' --cw 2") , ("M-r", spawn "xmonad --recompile && xmonad --restart") + , ("M-w", spawn "slock") , ("M-S-e", io exitSuccess) , ("M-j", windows W.focusDown) , ("M-k", windows W.focusUp) @@ -92,4 +93,5 @@ main = (map show [1 .. 9]) , startupHook = do spawnOnce "feh --bg-fill --no-fehbg --randomize /home/tom/src/nixos/wallpapers" + spawnOnce "xautolock -locker slock -time 1" } -- cgit v1.2.3