libkookie: i3: various updates to fonts, init config, and keybinding

wip/yesman
Katharina Fey 3 years ago
parent 49b086193f
commit 5bbf8cc19b
  1. 5
      infra/libkookie/configuration/workstation/i3/tempest.nix
  2. 5
      infra/libkookie/modules/workstation/ui/i3/core/keys.nix
  3. 73
      infra/libkookie/modules/workstation/ui/i3/core/setup.nix
  4. 6
      infra/libkookie/modules/workstation/ui/i3/core/tools/i3-scrcap.nix

@ -12,11 +12,14 @@
wallpaper = /home/Pictures/Wallpapers/small-memory.webp;
# TODO: hook into the "fonts" module?
fonts = [ "Iosevka:12" ];
fonts = [ "Iosevka Kookie:13" ];
networkmanager = false;
term = pkgs.kitty;
i3Status.segments = ["ipv6" "disk /" "ethernet _first_" "load" "tztime local"];
};
# ??? Why is this required
home.packages = [ pkgs.iosevka ];
}

@ -61,5 +61,8 @@
# Some layout modifiers
"${modifier}+3" = "layout default";
"${modifier}+4" = "layout tabbed";
"${modifier}+5" = "layout stacked";
"${modifier}+5" = "layout stacked";
# Select parent container
"${modifier}+a" = "focus parent";
}

@ -23,48 +23,41 @@ in
extraConfig = with pkgs;
let
fehCmd = "${feh}/bin/feh --bg-fill ${cfg.wallpaper}";
picomCmd = "";
nmCmd = if cfg.networkmanager
then "exec_always --no-startup-id ${networkmanagerapplet}/bin/nm-applet"
else "";
fehCommand = "${feh}/bin/feh --bg-fill ${cfg.wallpaper}";
in
''
# Setup compositor // TODO: gate this on the hm-module
exec_always --no-startup-id "${coreutils}/bin/pkill picom; ${picom}/bin/picom --config ~/.config/i3/picom.conf"
# Make CAPSLOCK into ESC because it's 2018
#
# Okay actually this is slightly more complicated than that. I'm binding
# CAPSLOCK to HYPER, so that I can use it as a modifier in emacs, but then
# using xcape(1) to also make short CAPSLOCK presses into ESCAPE.
exec_always --no-startup-id "${xorg.xmodmap}/bin/setxkbmap -layout us -variant altgr-intl -option caps:hyper"
exec ${xcape}/bin/xcape -e "#66=Escape" -t 150
# Set the desired wallpaper
exec_always --no-startup-id ${fehCmd}
# Start nm-applet if networkmanager is enabled
${nmCmd}
bar {
status_command ${i3status}/bin/i3status -c ~/.config/i3/i3status.conf
position bottom
bindsym button4 nop
bindsym button5 nop
colors {
background #0F0F0F
statusline #D5D5D5
}
''
# Setup compositor
exec_always --no-startup-id "${coreutils}/bin/pkill picom; ${picom}/bin/picom --config ~/.config/i3/picom.conf"
# Make CAPSLOCK into ESC because it's 2018
#
# Okay actually this is slightly more complicated than that. I'm binding
# CAPSLOCK to HYPER, so that I can use it as a modifier in emacs, but then
# using xcape(1) to also make short CAPSLOCK presses into ESCAPE.
exec_always --no-startup-id "${xorg.xmodmap}/bin/setxkbmap -layout us -variant altgr-intl -option caps:hyper"
exec ${xcape}/bin/xcape -e "#66=Escape" -t 150
# Always set a wallpaper
exec_always --no-startup-id ${fehCommand}
bar {
status_command ${i3status}/bin/i3status -c ~/.config/i3/i3status.conf
position bottom
bindsym button4 nop
bindsym button5 nop
colors {
background #0F0F0F
statusline #D5D5D5
}
focus_follows_mouse no
# Layout and design settings that should _really_ be in the module
default_border pixel 3
client.focused #4c7899 #285577 #ffffff #F73E5F #666666
'';
}
focus_follows_mouse no
# Layout and design settings that should _really_ be in the module
default_border pixel 3
client.focused #4c7899 #285577 #ffffff #F73E5F #666666
'';
};
xdg.configFile."i3/picom.conf" = (import ./picom.nix args);

@ -7,10 +7,10 @@
# TODO: this is broken and I don't know why...
{ pkgs, ... }: with pkgs; writeShellScript "libkookie-i3-move" ''
{ pkgs, ... }: with pkgs; writeShellScript "libkookie-i3-scrcap" ''
echo "Taking screenshot at $(date)" >> /home/.local/scrcap.log
echo "${scrot}/bin/scrot" >> /home/.local/scrcap.log
echo "${gnome3.gnome-screenshot}/bin/gnome-screenshot" >> /home/.local/scrcap.log
${scrot}/bin/scrot -D :0 -s >> /home/.local/scrcap.log
${gnome3.gnome-screenshot}/bin/gnome-screenshot -a >> /home/.local/scrcap.log
echo "scrot exit: $?" >> /home/.local/scrcap.log
''

Loading…
Cancel
Save