I3: Difference between revisions
imported>LinArcX mNo edit summary |
imported>LinArcX Show i3blocks [BLOCKS] properly. |
||
| Line 6: | Line 6: | ||
{{file|/etc/nixos/configuration.nix|nix| | {{file|/etc/nixos/configuration.nix|nix| | ||
<nowiki> | <nowiki> | ||
{ config, pkgs, callPackage, ... }: | { config, pkgs, callPackage, ... }: | ||
environment.pathsToLink = [ "/libexec" ]; # links /libexec from derivations to /run/current-system/sw | |||
... | ... | ||
services.xserver = { | services.xserver = { | ||
| Line 41: | Line 43: | ||
<syntaxhighlight lang="nix" inline>services.xserver.windowManager.i3.package = pkgs.i3-gaps;</syntaxhighlight> | <syntaxhighlight lang="nix" inline>services.xserver.windowManager.i3.package = pkgs.i3-gaps;</syntaxhighlight> | ||
===i3blocks=== | |||
After installing and enabling i3blocks, you may notice that i3block won't work. why? | |||
It seems that i3blocks read it's contents from a hardcoded path in /etc by default. | |||
Since in nixos, this path look something like: | |||
{{file|Path of i3blocks in nixos|nix| | |||
<nowiki> | |||
/nix/store/k78nc1bplhy4yjblqwlc14h6rdisix3w-i3blocks-1.4/libexec/i3blocks/[BLOCKS] | |||
</nowiki> | |||
}} | |||
And it can't find this path, so we have to create a link to this path by adding this line to configuration.nix file: | |||
{{file|/etc/nixos/configuration.nix|nix| | |||
<nowiki> | |||
environment.pathsToLink = [ "/libexec" ]; | |||
</nowiki> | |||
}} | |||
===DConf=== | ===DConf=== | ||