diff options
author | Ben Sima <ben@bsima.me> | 2018-05-30 08:28:37 -0700 |
---|---|---|
committer | Ben Sima <ben@bsima.me> | 2018-05-30 08:28:37 -0700 |
commit | d6ee0e228470a3f13dc17f465da770e940f6c4ea (patch) | |
tree | c69ae90af9273fb226d213a668213c039f337399 | |
parent | 4e2881a9dea16ee2af4f618b66a7aeace2bba39f (diff) |
Fix backlighting screen stuff on laptop
-rw-r--r-- | home.nix | 6 | ||||
-rw-r--r-- | packages.nix | 1 | ||||
-rw-r--r-- | xmonad.hs | 34 |
3 files changed, 30 insertions, 11 deletions
@@ -50,6 +50,12 @@ enable = true; }; + services.redshift = { + enable = true; + latitude = "33.044444"; + longitude = "-117.271667"; + }; + xsession = { enable = true; windowManager.xmonad = { diff --git a/packages.nix b/packages.nix index fe14408..162db32 100644 --- a/packages.nix +++ b/packages.nix @@ -41,6 +41,7 @@ pkgs.vlc pkgs.vpnc pkgs.w3m pkgs.wakatime +#pkgs.xorg.xbacklight pkgs.xterm pkgs.yank pkgs.youtube-dl @@ -1,18 +1,30 @@ import XMonad.Config import XMonad +import XMonad.Util.CustomKeys (customKeys) import XMonad.Hooks.EwmhDesktops (ewmh) import XMonad.Hooks.ManageDocks --import System.Taffybar.Support.PagerHints (pagerHints) +delKeys conf@(XConfig {modMask = modMask}) = + [ (modMask, xK_p) ] + +insKeys :: XConfig l -> [((KeyMask, KeySym), X ())] +insKeys conf@(XConfig {modMask = modMask}) = + [ ((0, xK_F5), spawn "xbacklight -dec 1") + , ((0, xK_F6), spawn "xbacklight -inc 1") + , ((modMask, xK_o), spawn "dmenu") + ] + main = - xmonad $ - ewmh $ - docks $ - def - { modMask = mod4Mask -- ^ super instead of alt - , normalBorderColor = "#002b36" -- ^ solarized dark - , focusedBorderColor = "#eee8d5" -- ^ solarized light - , manageHook = manageDocks <+> manageHook defaultConfig - , layoutHook = avoidStruts $ layoutHook defaultConfig - , terminal = "/home/ben/.nix-profile/bin/xterm" - } + xmonad $ + ewmh $ + docks $ + def + { modMask = mod4Mask -- ^ super instead of alt + , normalBorderColor = "#002b36" -- ^ solarized dark + , focusedBorderColor = "#eee8d5" -- ^ solarized light + , manageHook = manageDocks <+> manageHook defaultConfig + , layoutHook = avoidStruts $ layoutHook defaultConfig + , terminal = "/home/ben/.nix-profile/bin/xterm" + , keys = customKeys delKeys insKeys + } |