2020-10-01 15:46:04 -07:00
|
|
|
# modules/desktop/term/st.nix
|
|
|
|
#
|
|
|
|
# I like (x)st. This appears to be a controversial opinion; don't tell anyone,
|
|
|
|
# mkay?
|
|
|
|
|
|
|
|
{ options, config, lib, pkgs, ... }:
|
2020-03-28 22:48:43 -07:00
|
|
|
|
|
|
|
with lib;
|
2020-10-01 15:46:04 -07:00
|
|
|
with lib.my;
|
|
|
|
let cfg = config.modules.desktop.term.st;
|
|
|
|
in {
|
2020-03-28 22:48:43 -07:00
|
|
|
options.modules.desktop.term.st = {
|
2020-10-01 15:46:04 -07:00
|
|
|
enable = mkBoolOpt false;
|
2020-03-28 22:48:43 -07:00
|
|
|
};
|
|
|
|
|
2020-10-01 15:46:04 -07:00
|
|
|
config = mkIf cfg.enable {
|
2020-03-28 22:48:43 -07:00
|
|
|
# xst-256color isn't supported over ssh, so revert to a known one
|
2020-10-01 15:46:04 -07:00
|
|
|
modules.shell.zsh.rcInit = ''
|
|
|
|
[ "$TERM" = xst-256color ] && export TERM=xterm-256color
|
|
|
|
'';
|
2020-03-28 22:48:43 -07:00
|
|
|
|
2020-10-01 15:46:04 -07:00
|
|
|
user.packages = with pkgs; [
|
2020-03-28 22:48:43 -07:00
|
|
|
xst # st + nice-to-have extensions
|
|
|
|
(makeDesktopItem {
|
|
|
|
name = "xst";
|
|
|
|
desktopName = "Suckless Terminal";
|
|
|
|
genericName = "Default terminal";
|
|
|
|
icon = "utilities-terminal";
|
|
|
|
exec = "${xst}/bin/xst";
|
|
|
|
categories = "Development;System;Utility";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
};
|
|
|
|
}
|