In XFCE I can navigate to Keyboard > Application Shortcuts to set keyboard shortcuts. For example, by default xfce4-appfinder is set to Alt+F3 by default. These shortcuts are specified in the filesystem at ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml.

When using NixOS, it is possible to specify these shortcuts in the xfce options in configuration.nix, so that they can be automatically set when the configuration is installed on a new computer?

  • If there's a file with default keyboard shortcuts (which I think is likely) then perhaps that can be used to specify the (system-wide) shortcuts via configuration.nix. Check your /nix/store for a file named xfce4-keyboard-shortcuts.xml. If it exists that will specify which package we're dealing with – Emmanuel Rosa May 23 '18 at 17:07
  • It's there! /nix/store/pd6g8yr5jal7f4m3v4ln8hddr75jkmqi-system-path/etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml. – Matthew Piziak May 23 '18 at 23:54
  • there could be nixos module that creates /etc/xdg/xfce4/xfconf/xfce-perchannel-xml/xfce4-keyboard-shortcuts.xml. However xfce might not pick it up yet from there. It might need different configure flags to look i.e. --sysconfdir=/etc to look into /etc. – Mic92 May 24 '18 at 12:10
  • @MatthewPiziak, I recommend you open an issue at github.com/NixOS/nixpkgs. As Mic92 mentioned, a NixOS module will need to be created. Totally feasible. – Emmanuel Rosa May 24 '18 at 13:36

It is not possible at the moment. NixOS module don't write to /home but to /etc. Since the Nix language supports writing xml, keyboard configuration could be become a home-manager module.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.