XMonad: Difference between revisions

Pigs (talk | contribs)
DHCP (talk | contribs)
m style fixes
 
Line 13: Line 13:
{{file|/etc/nixos/configuration.nix|nix|
{{file|/etc/nixos/configuration.nix|nix|
<nowiki>
<nowiki>
  services.xserver.windowManager.xmonad = {
services.xserver.windowManager.xmonad = {
    enable = true;
  enable = true;
    enableContribAndExtras = true;
  enableContribAndExtras = true;
  };
};
</nowiki>
</nowiki>
}}
}}
Line 29: Line 29:
{{file|/etc/nixos/configuration.nix|nix|
{{file|/etc/nixos/configuration.nix|nix|
<nowiki>
<nowiki>
...
services.xserver.windowManager.xmonad = {
   ...
   ...
   services.xserver.windowManager.xmonad = {
   extraPackages = haskellPackages: [  
    ...
    haskellPackages.monad-logger
    extraPackages = haskellPackages: [  
  ];
      haskellPackages.monad-logger
};
    ];
  };
</nowiki>
</nowiki>
}}
}}
Line 130: Line 130:


{{file|/etc/nixos/configuration.nix|nix|<nowiki>
{{file|/etc/nixos/configuration.nix|nix|<nowiki>
  services.xserver.displayManager.sessionCommands = ''
services.xserver.displayManager.sessionCommands = ''
    xset -dpms  # Disable Energy Star, as we are going to suspend anyway and it may hide "success" on that
  xset -dpms  # Disable Energy Star, as we are going to suspend anyway and it may hide "success" on that
    xset s blank # `noblank` may be useful for debugging  
  xset s blank # `noblank` may be useful for debugging  
    xset s 300 # seconds
  xset s 300 # seconds
    ${pkgs.lightlocker}/bin/light-locker --idle-hint &
  ${pkgs.lightlocker}/bin/light-locker --idle-hint &
  '';
'';
</nowiki>}}
</nowiki>}}


Line 144: Line 144:


{{file|/etc/nixos/configuration.nix|nix|<nowiki>
{{file|/etc/nixos/configuration.nix|nix|<nowiki>
  systemd.targets.hybrid-sleep.enable = true;
systemd.targets.hybrid-sleep.enable = true;
  services.logind.extraConfig = ''
services.logind.extraConfig = ''
    IdleAction=hybrid-sleep
  IdleAction=hybrid-sleep
    IdleActionSec=20s
  IdleActionSec=20s
  '';
'';
</nowiki>}}
</nowiki>}}


Line 198: Line 198:
==== Create a project around <code>xmonad.hs</code> ====
==== Create a project around <code>xmonad.hs</code> ====


<syntaxHighlight lang="bash">
<syntaxHighlight lang=console>
echo "xmonad" >> $HIE_BIOS_OUTPUT  
$ echo "xmonad" >> $HIE_BIOS_OUTPUT  
</syntaxHighlight>
</syntaxHighlight>