~magic_rb/dotfiles

6013c57702b183bd8e4659fd161cf1ece4e1b699 — Magic_RB 1 year, 1 month ago bbf9711
More xmonad keybindings and menus

Signed-off-by: Magic_RB <magic_rb@redalder.org>
2 files changed, 13 insertions(+), 1 deletions(-)

M home-manager/modules/xmonad/default.nix
M home-manager/modules/xmonad/xmonad.hs
M home-manager/modules/xmonad/default.nix => home-manager/modules/xmonad/default.nix +8 -1
@@ 54,6 54,7 @@ in {
        "screenshot" = lib.getExe pkgs.magic_rb.screenshot;
        "emacs-rofi" = lib.getExe pkgs.emacs-rofi;
        "notify" = lib.getExe pkgs.libnotify;
        "playerctl" = lib.getExe pkgs.playerctl;
        "reload" = pkgs.writeShellScript "xmonad-reload"
          ''
            ${lib.getExe pkgs.libnotify} -t 5000 "recompiling xmonad"


@@ 70,7 71,7 @@ in {
          ''
            export SUDO_ASKPASS=${pkgs.x11_ssh_askpass}/libexec/x11-ssh-askpass

            _options="toggle-mic\ntoggle-radio\nscreenshot-all\nscreenshot-select\nscreenshot-focused\nsuspend\nreboot\nkexec\npoweroff"
            _options="toggle-mic\ntoggle-radio\nscreenshot-all\nscreenshot-select\nscreenshot-focused\nsuspend\nreboot\nkexec\npoweroff\nlogout\nnmtui"

            _option="$(echo -e $_options | emacs-rofi "command: " 90 30 | awk '{print $1}' | tr -d '\r\n')"
            if [ ''${#_option} -gt 0 ]


@@ 109,6 110,12 @@ in {
                  sudo -A kexec -l /run/current-system/kernel --initrd=/run/current-system/initrd --reuse-cmdline
                  systemctl kexec
                  ;;
                logout)
                  loginctl terminate-session $XDG_SESSION_ID
                  ;;
                nmtui)
                  alacritty -e nmtui
                  ;;
                *)
                  ;;
              esac

M home-manager/modules/xmonad/xmonad.hs => home-manager/modules/xmonad/xmonad.hs +5 -0
@@ 144,6 144,11 @@ myKeymap c =
     , ("<XF86MonBrightnessUp>"   , spawn "@brightnessctl@ set +5%")
     , ("<XF86MonBrightnessDown>" , spawn "@brightnessctl@ set 5%-")

     , ("<XF86AudioPlay>"         , spawn "@notify@ -t 5000 \"Music: Play\"" >> spawn "@playerctl@ play-pause")
     , ("<XF86AudioStop>"         , spawn "@notify@ -t 5000 \"Music: Stop\"" >> spawn "@playerctl@ stop")
     , ("<XF86AudioPrev>"         , spawn "@notify@ -t 5000 \"Music: Prev\"" >> spawn "@playerctl@ previous")
     , ("<XF86AudioNext>"         , spawn "@notify@ -t 5000 \"Music: Next\"" >> spawn "@playerctl@ next")

     , ("M-<F1>", spawn "@auxmenu@")
    ]
    ++