From f775d3a7e643d8432b867632c10e000d40b051c7 Mon Sep 17 00:00:00 2001 From: tv Date: Wed, 24 Apr 2019 23:44:37 +0200 Subject: tv: add Xresources module --- tv/2configs/xserver/Xresources.nix | 116 +++++++++++++++++++------------------ tv/2configs/xserver/default.nix | 5 +- 2 files changed, 63 insertions(+), 58 deletions(-) (limited to 'tv/2configs/xserver') diff --git a/tv/2configs/xserver/Xresources.nix b/tv/2configs/xserver/Xresources.nix index d032efc7d..679b77dcc 100644 --- a/tv/2configs/xserver/Xresources.nix +++ b/tv/2configs/xserver/Xresources.nix @@ -1,58 +1,60 @@ -{ config, lib, pkgs, ... }: - with import ; - -pkgs.writeText "Xresources" /* xdefaults */ '' - URxvt*cutchars: "\\`\"'&()*,;<=>?@[]^{|}‘’" - URxvt*eightBitInput: false - URxvt*font: -*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1 - URxvt*boldFont: -*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1 - URxvt*scrollBar: false - URxvt*background: #050505 - URxvt*foreground: #d0d7d0 - URxvt*cursorColor: #f042b0 - URxvt*cursorColor2: #f0b000 - URxvt*cursorBlink: off - URxvt*jumpScroll: true - URxvt*allowSendEvents: false - URxvt*charClass: 33:48,37:48,45-47:48,64:48,38:48,61:48,63:48 - URxvt*cutNewline: False - URxvt*cutToBeginningOfLine: False - - URxvt*color0: #232342 - URxvt*color3: #c07000 - URxvt*color4: #4040c0 - URxvt*color7: #c0c0c0 - URxvt*color8: #707070 - URxvt*color9: #ff6060 - URxvt*color10: #70ff70 - URxvt*color11: #ffff70 - URxvt*color12: #7070ff - URxvt*color13: #ff50ff - URxvt*color14: #70ffff - URxvt*color15: #ffffff - - URxvt*iso14755: False - - URxvt*urgentOnBell: True - URxvt*visualBell: True - - ! ref https://github.com/muennich/urxvt-perls - URxvt*perl-ext: default,url-select - URxvt*keysym.M-u: perl:url-select:select_next - URxvt*url-select.launcher: /etc/per-user/${config.krebs.build.user.name}/bin/ff -new-tab - URxvt*url-select.underline: true - URxvt*colorUL: #4682B4 - URxvt.perl-lib: ${pkgs.urxvt_perls}/lib/urxvt/perl - URxvt*saveLines: 10000 - - root-urxvt*background: #230000 - root-urxvt*foreground: #e0c0c0 - root-urxvt*BorderColor: #400000 - root-urxvt*color0: #800000 - - fzmenu-urxvt*background: rgb:42/23/42 - fzmenu-urxvt*externalBorder: 1 - fzmenu-urxvt*geometry: 70x9 - fzmenu-urxvt*internalBorder: 1 -'' +{ config, pkgs, ... }: { + + tv.Xresources = { + "URxvt*cutchars" = ''"\\`\"'&()*,;<=>?@[]^{|}‘’"''; + "URxvt*eightBitInput" = "false"; + "URxvt*font" = "-*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1"; + "URxvt*boldFont" = "-*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1"; + "URxvt*scrollBar" = "false"; + "URxvt*background" = "#050505"; + "URxvt*foreground" = "#d0d7d0"; + "URxvt*cursorColor" = "#f042b0"; + "URxvt*cursorColor2" = "#f0b000"; + "URxvt*cursorBlink" = "off"; + "URxvt*jumpScroll" = "true"; + "URxvt*allowSendEvents" = "false"; + "URxvt*charClass" = "33:48,37:48,45-47:48,64:48,38:48,61:48,63:48"; + "URxvt*cutNewline" = "False"; + "URxvt*cutToBeginningOfLine" = "False"; + + "URxvt*color0" = "#232342"; + "URxvt*color3" = "#c07000"; + "URxvt*color4" = "#4040c0"; + "URxvt*color7" = "#c0c0c0"; + "URxvt*color8" = "#707070"; + "URxvt*color9" = "#ff6060"; + "URxvt*color10" = "#70ff70"; + "URxvt*color11" = "#ffff70"; + "URxvt*color12" = "#7070ff"; + "URxvt*color13" = "#ff50ff"; + "URxvt*color14" = "#70ffff"; + "URxvt*color15" = "#ffffff"; + + "URxvt*iso14755" = "False"; + + "URxvt*urgentOnBell" = "True"; + "URxvt*visualBell" = "True"; + + # ref https://github.com/muennich/urxvt-perls + "URxvt*perl-ext" = "default,url-select"; + "URxvt*keysym.M-u" = "perl:url-select:select_next"; + "URxvt*url-select.launcher" = + "/etc/per-user/${config.krebs.build.user.name}/bin/ff -new-tab"; + "URxvt*url-select.underline" = "true"; + "URxvt*colorUL" = "#4682B4"; + "URxvt.perl-lib" = "${pkgs.urxvt_perls}/lib/urxvt/perl"; + "URxvt*saveLines" = "10000"; + + "root-urxvt*background" = "#230000"; + "root-urxvt*foreground" = "#e0c0c0"; + "root-urxvt*BorderColor" = "#400000"; + "root-urxvt*color0" = "#800000"; + + "fzmenu-urxvt*background" = "rgb:42/23/42"; + "fzmenu-urxvt*externalBorder" = "1"; + "fzmenu-urxvt*geometry" = "70x9"; + "fzmenu-urxvt*internalBorder" = "1"; + }; + +} diff --git a/tv/2configs/xserver/default.nix b/tv/2configs/xserver/default.nix index 051e12ef0..e2160258c 100644 --- a/tv/2configs/xserver/default.nix +++ b/tv/2configs/xserver/default.nix @@ -9,6 +9,10 @@ let }; in { + imports = [ + ./Xresources.nix + ]; + environment.systemPackages = [ pkgs.ff pkgs.font-size @@ -73,7 +77,6 @@ in { ${pkgs.xorg.xhost}/bin/xhost -LOCAL: } & ${pkgs.xorg.xmodmap}/bin/xmodmap ${import ./Xmodmap.nix args} & - ${pkgs.xorg.xrdb}/bin/xrdb ${import ./Xresources.nix args} & ${pkgs.xorg.xsetroot}/bin/xsetroot -solid '#1c1c1c' & wait ''; -- cgit v1.2.3 From 71ed9c9730e8a711418b11b052ec9bbf867f1074 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 25 Apr 2019 00:07:31 +0200 Subject: tv Xresources: fix URxvt*url-select.launcher path --- tv/2configs/xserver/Xresources.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tv/2configs/xserver') diff --git a/tv/2configs/xserver/Xresources.nix b/tv/2configs/xserver/Xresources.nix index 679b77dcc..84b37f672 100644 --- a/tv/2configs/xserver/Xresources.nix +++ b/tv/2configs/xserver/Xresources.nix @@ -40,7 +40,7 @@ with import ; "URxvt*perl-ext" = "default,url-select"; "URxvt*keysym.M-u" = "perl:url-select:select_next"; "URxvt*url-select.launcher" = - "/etc/per-user/${config.krebs.build.user.name}/bin/ff -new-tab"; + "/etc/profiles/per-user/${config.krebs.build.user.name}/bin/ff -new-tab"; "URxvt*url-select.underline" = "true"; "URxvt*colorUL" = "#4682B4"; "URxvt.perl-lib" = "${pkgs.urxvt_perls}/lib/urxvt/perl"; -- cgit v1.2.3 From 070464b4ef9f51d19276a468c655439b2b5af330 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 25 Apr 2019 00:13:47 +0200 Subject: tv Xresources: simplify URxvt*charClass --- tv/2configs/xserver/Xresources.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tv/2configs/xserver') diff --git a/tv/2configs/xserver/Xresources.nix b/tv/2configs/xserver/Xresources.nix index 84b37f672..4d2520ced 100644 --- a/tv/2configs/xserver/Xresources.nix +++ b/tv/2configs/xserver/Xresources.nix @@ -14,7 +14,7 @@ with import ; "URxvt*cursorBlink" = "off"; "URxvt*jumpScroll" = "true"; "URxvt*allowSendEvents" = "false"; - "URxvt*charClass" = "33:48,37:48,45-47:48,64:48,38:48,61:48,63:48"; + "URxvt*charClass" = "33:48,37-38:48,45-47:48,61:48,63-64:48"; "URxvt*cutNewline" = "False"; "URxvt*cutToBeginningOfLine" = "False"; -- cgit v1.2.3 From 4e096de5fc0516d3660b617f4c06a92831cdbd70 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 25 Apr 2019 00:15:06 +0200 Subject: tv Xresources: URxvt*modifier = mod1 --- tv/2configs/xserver/Xresources.nix | 1 + 1 file changed, 1 insertion(+) (limited to 'tv/2configs/xserver') diff --git a/tv/2configs/xserver/Xresources.nix b/tv/2configs/xserver/Xresources.nix index 4d2520ced..b6c43b71b 100644 --- a/tv/2configs/xserver/Xresources.nix +++ b/tv/2configs/xserver/Xresources.nix @@ -45,6 +45,7 @@ with import ; "URxvt*colorUL" = "#4682B4"; "URxvt.perl-lib" = "${pkgs.urxvt_perls}/lib/urxvt/perl"; "URxvt*saveLines" = "10000"; + "URxvt*modifier" = "mod1"; "root-urxvt*background" = "#230000"; "root-urxvt*foreground" = "#e0c0c0"; -- cgit v1.2.3 From 542d290543b9c9965f906548397ba0d8b761898e Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 25 Apr 2019 00:17:25 +0200 Subject: tv: add urxvt config module --- tv/2configs/xserver/Xresources.nix | 61 ------------------------------- tv/2configs/xserver/default.nix | 15 +------- tv/2configs/xserver/urxvt.nix | 73 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 74 insertions(+), 75 deletions(-) delete mode 100644 tv/2configs/xserver/Xresources.nix create mode 100644 tv/2configs/xserver/urxvt.nix (limited to 'tv/2configs/xserver') diff --git a/tv/2configs/xserver/Xresources.nix b/tv/2configs/xserver/Xresources.nix deleted file mode 100644 index b6c43b71b..000000000 --- a/tv/2configs/xserver/Xresources.nix +++ /dev/null @@ -1,61 +0,0 @@ -with import ; -{ config, pkgs, ... }: { - - tv.Xresources = { - "URxvt*cutchars" = ''"\\`\"'&()*,;<=>?@[]^{|}‘’"''; - "URxvt*eightBitInput" = "false"; - "URxvt*font" = "-*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1"; - "URxvt*boldFont" = "-*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1"; - "URxvt*scrollBar" = "false"; - "URxvt*background" = "#050505"; - "URxvt*foreground" = "#d0d7d0"; - "URxvt*cursorColor" = "#f042b0"; - "URxvt*cursorColor2" = "#f0b000"; - "URxvt*cursorBlink" = "off"; - "URxvt*jumpScroll" = "true"; - "URxvt*allowSendEvents" = "false"; - "URxvt*charClass" = "33:48,37-38:48,45-47:48,61:48,63-64:48"; - "URxvt*cutNewline" = "False"; - "URxvt*cutToBeginningOfLine" = "False"; - - "URxvt*color0" = "#232342"; - "URxvt*color3" = "#c07000"; - "URxvt*color4" = "#4040c0"; - "URxvt*color7" = "#c0c0c0"; - "URxvt*color8" = "#707070"; - "URxvt*color9" = "#ff6060"; - "URxvt*color10" = "#70ff70"; - "URxvt*color11" = "#ffff70"; - "URxvt*color12" = "#7070ff"; - "URxvt*color13" = "#ff50ff"; - "URxvt*color14" = "#70ffff"; - "URxvt*color15" = "#ffffff"; - - "URxvt*iso14755" = "False"; - - "URxvt*urgentOnBell" = "True"; - "URxvt*visualBell" = "True"; - - # ref https://github.com/muennich/urxvt-perls - "URxvt*perl-ext" = "default,url-select"; - "URxvt*keysym.M-u" = "perl:url-select:select_next"; - "URxvt*url-select.launcher" = - "/etc/profiles/per-user/${config.krebs.build.user.name}/bin/ff -new-tab"; - "URxvt*url-select.underline" = "true"; - "URxvt*colorUL" = "#4682B4"; - "URxvt.perl-lib" = "${pkgs.urxvt_perls}/lib/urxvt/perl"; - "URxvt*saveLines" = "10000"; - "URxvt*modifier" = "mod1"; - - "root-urxvt*background" = "#230000"; - "root-urxvt*foreground" = "#e0c0c0"; - "root-urxvt*BorderColor" = "#400000"; - "root-urxvt*color0" = "#800000"; - - "fzmenu-urxvt*background" = "rgb:42/23/42"; - "fzmenu-urxvt*externalBorder" = "1"; - "fzmenu-urxvt*geometry" = "70x9"; - "fzmenu-urxvt*internalBorder" = "1"; - }; - -} diff --git a/tv/2configs/xserver/default.nix b/tv/2configs/xserver/default.nix index e2160258c..95198ff9e 100644 --- a/tv/2configs/xserver/default.nix +++ b/tv/2configs/xserver/default.nix @@ -10,7 +10,7 @@ let in { imports = [ - ./Xresources.nix + ./urxvt.nix ]; environment.systemPackages = [ @@ -150,19 +150,6 @@ in { }; }; - systemd.services.urxvtd = { - wantedBy = [ "graphical.target" ]; - restartIfChanged = false; - serviceConfig = { - SyslogIdentifier = "urxvtd"; - ExecStart = "${pkgs.rxvt_unicode}/bin/urxvtd"; - Restart = "always"; - RestartSec = "2s"; - StartLimitBurst = 0; - User = cfg.user.name; - }; - }; - tv.slock = { enable = true; user = cfg.user; diff --git a/tv/2configs/xserver/urxvt.nix b/tv/2configs/xserver/urxvt.nix new file mode 100644 index 000000000..2d504e165 --- /dev/null +++ b/tv/2configs/xserver/urxvt.nix @@ -0,0 +1,73 @@ +with import ; +{ config, pkgs, ... }: let + cfg.user = config.krebs.build.user; +in { + systemd.services.urxvtd = { + wantedBy = [ "graphical.target" ]; + restartIfChanged = false; + serviceConfig = { + SyslogIdentifier = "urxvtd"; + ExecStart = "${pkgs.rxvt_unicode}/bin/urxvtd"; + Restart = "always"; + RestartSec = "2s"; + StartLimitBurst = 0; + User = cfg.user.name; + }; + }; + tv.Xresources = { + "URxvt*cutchars" = ''"\\`\"'&()*,;<=>?@[]^{|}‘’"''; + "URxvt*eightBitInput" = "false"; + "URxvt*font" = "-*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1"; + "URxvt*boldFont" = "-*-clean-*-*-*-*-*-*-*-*-*-*-iso10646-1"; + "URxvt*scrollBar" = "false"; + "URxvt*background" = "#050505"; + "URxvt*foreground" = "#d0d7d0"; + "URxvt*cursorColor" = "#f042b0"; + "URxvt*cursorColor2" = "#f0b000"; + "URxvt*cursorBlink" = "off"; + "URxvt*jumpScroll" = "true"; + "URxvt*allowSendEvents" = "false"; + "URxvt*charClass" = "33:48,37-38:48,45-47:48,61:48,63-64:48"; + "URxvt*cutNewline" = "False"; + "URxvt*cutToBeginningOfLine" = "False"; + + "URxvt*color0" = "#232342"; + "URxvt*color3" = "#c07000"; + "URxvt*color4" = "#4040c0"; + "URxvt*color7" = "#c0c0c0"; + "URxvt*color8" = "#707070"; + "URxvt*color9" = "#ff6060"; + "URxvt*color10" = "#70ff70"; + "URxvt*color11" = "#ffff70"; + "URxvt*color12" = "#7070ff"; + "URxvt*color13" = "#ff50ff"; + "URxvt*color14" = "#70ffff"; + "URxvt*color15" = "#ffffff"; + + "URxvt*iso14755" = "False"; + + "URxvt*urgentOnBell" = "True"; + "URxvt*visualBell" = "True"; + + # ref https://github.com/muennich/urxvt-perls + "URxvt*perl-ext" = "default,url-select"; + "URxvt*keysym.M-u" = "perl:url-select:select_next"; + "URxvt*url-select.launcher" = + "/etc/profiles/per-user/${cfg.user.name}/bin/ff -new-tab"; + "URxvt*url-select.underline" = "true"; + "URxvt*colorUL" = "#4682B4"; + "URxvt.perl-lib" = "${pkgs.urxvt_perls}/lib/urxvt/perl"; + "URxvt*saveLines" = "10000"; + "URxvt*modifier" = "mod1"; + + "root-urxvt*background" = "#230000"; + "root-urxvt*foreground" = "#e0c0c0"; + "root-urxvt*BorderColor" = "#400000"; + "root-urxvt*color0" = "#800000"; + + "fzmenu-urxvt*background" = "rgb:42/23/42"; + "fzmenu-urxvt*externalBorder" = "1"; + "fzmenu-urxvt*geometry" = "70x9"; + "fzmenu-urxvt*internalBorder" = "1"; + }; +} -- cgit v1.2.3 From 73e89ece549bad03d97326cc94e9ba59a762d298 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 25 Apr 2019 00:23:39 +0200 Subject: tv: add sxiv config module --- tv/2configs/xserver/default.nix | 2 +- tv/2configs/xserver/sxiv.nix | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 tv/2configs/xserver/sxiv.nix (limited to 'tv/2configs/xserver') diff --git a/tv/2configs/xserver/default.nix b/tv/2configs/xserver/default.nix index 95198ff9e..012caff73 100644 --- a/tv/2configs/xserver/default.nix +++ b/tv/2configs/xserver/default.nix @@ -10,6 +10,7 @@ let in { imports = [ + ./sxiv.nix ./urxvt.nix ]; @@ -18,7 +19,6 @@ in { pkgs.font-size pkgs.gitAndTools.qgit pkgs.mpv - pkgs.sxiv pkgs.xdotool pkgs.xsel pkgs.zathura diff --git a/tv/2configs/xserver/sxiv.nix b/tv/2configs/xserver/sxiv.nix new file mode 100644 index 000000000..10e450da4 --- /dev/null +++ b/tv/2configs/xserver/sxiv.nix @@ -0,0 +1,12 @@ +with import ; +{ config, pkgs, ... }: let + cfg.user = config.krebs.build.user; +in { + tv.Xresources = { + "Sxiv.foreground" = "#232323"; + "Sxiv.background" = "#424242"; + }; + users.users.${cfg.user.name}.packages = [ + pkgs.sxiv + ]; +} -- cgit v1.2.3