fonts & waybar

This commit is contained in:
Sam 2024-05-31 00:17:16 +01:00
parent f5094f4749
commit afc6ef3e56
8 changed files with 247 additions and 28 deletions

View File

@ -3,10 +3,20 @@
imports = [ imports = [
./zsh.nix ./zsh.nix
./nixvim.nix ./nixvim.nix
./fonts.nix
] ; ] ;
home.packages = [
pkgs.ripgrep # Global home packages without config go here (for all hosts and users)
]; home.packages = builtins.attrValues {
inherit (pkgs)
ripgrep
fzf
eza
pciutils
tree
jq
coreutils
;};
home.stateVersion = "23.11"; home.stateVersion = "23.11";
} }

View File

@ -0,0 +1,10 @@
{ pkgs, ... }:
{
fonts.fontconfig.enable = true;
home.packages = [
pkgs.noto-fonts
pkgs.nerdfonts # loads the complete collection. look into overide for FiraMono or potentially mononoki
pkgs.meslo-lgs-nf
];
}

View File

@ -10,7 +10,211 @@
}; };
programs.waybar = { programs.waybar = {
enable = true; enable = true;
#package = "";
systemd.enable = true; systemd.enable = true;
};
settings = {
primary = {
mode = "dock";
height = 30;
margin = "6";
spacing = 5;
modules-left = [
"custom/menu"
"wlr/workspaces"];
modules-center = [
"clock"
];
modules-right = [
"cpu"
"memory"
"network"
"pulseaudio"
"battery"
"tray"
"custom/exit"
"custom/hostname"
];
"wlr/workspaces" = {
"format" = "{icon}";
"on-click" = "activate";
"format-icons"= {
"1" = "";
"2" = "";
"3" = "";
"4" = "";
"5" = "";
"urgent" = "";
"active" = "";
"default" = "";
};
};
"clock" = {
"format" = "<span> </span>{:%m/%d %H:%M}";
"tooltip-format" = "<big>{:%B %Y}</big>\n<tt><small>{calendar}</small></tt>";
"on-click" = "calendar";
};
"cpu"= {
"interval" = 10;
"format" = " {}%";
"max-length" = 10;
"on-click" = "";
};
"memory" = {
"interval" = 30;
"format" = " {}%";
"format-alt" = " {used:0.1f}G";
"max-length" = 10;
};
"network" = {
"format-wifi" = " {signalStrength}%";
"format-ethernet" = " wired";
"format-disconnected" = "";
"on-click" = "bash ~/.config/waybar/scripts/rofi-wifi-menu.sh";
};
"battery" = {
"bat" = "BAT0";
"adapter" = "ADP0";
"interval" = 60;
"states" = {
"warning" = 30;
"critical" = 15;
};
"max-length" = 20;
"format" = "{icon} {capacity}%";
"format-warning" = "{icon} {capacity}%";
"format-critical" = "{icon} {capacity}%";
"format-charging" = "<span font-family='Font Awesome 6 Free'></span> {capacity}%";
"format-plugged" = " {capacity}%";
"format-alt" = "{icon} {time}";
"format-full" = " {capacity}%";
"format-icons" = [" " " " " " " " " "];
};
"tray" = {
"spacing" = 10;
};
"custom/menu" = {
"format" = "";
"on-click" = "rofi -show drun";
};
"custom/hostname" = {
"exec" = "echo $USER@$(hostname)";
"on-click" = "alacritty";
};
"custom/exit" = {
"format" = "";
"on-click" = "wlogout";
};
"pulseaudio" = {
"format" = "{icon} {volume}%";
"format-muted" = " 0%";
"format-icons" = {
"headphone" = "";
"headset" = "";
"portable" = "";
"default" = [ "" "" "" ];
};
"on-click" = "pavucontrol";
};
};
};
style = ''
* {
font-family: JetBrainsMono Nerd Font;
font-size: 12pt;
padding: 0 8px;
}
.modules-right {
margin-right: -15px;
}
.modules-left {
margin-left: -15px;
}
window#waybar {
color: white;
background-color: #002635;
opacity: 0.95;
padding: 0;
border-radius: 10px;
}
window#waybar.bottom {
opacity: 0.90;
background-color: #002635;
border: 2px solid #14747e;
border-radius: 10px;
}
#workspaces button {
padding: 0 5px;
color: #7984A4;
background-color: transparent;
box-shadow: inset 0 -3px transparent;
border: none;
border-radius: 0;
}
#workspaces button.hidden {
background-color: #002635;
color: #869696;
}
#workspaces button.focused {
color: #bf616a;
}
#workspaces button.active {
color: #6a92d7;
}
#workspaces button.urgent {
background-color: #eb4d4b;
}
#clock {
padding-left: 15px;
padding-right: 15px;
margin-top: 0;
margin-bottom: 0;
border-radius: 10px;
}
#tray {
color: #a1a19a;
}
#custom-hostname {
background-color: white;
color: #002635;
padding-left: 15px;
padding-right: 18px;
margin-right: 0;
margin-top: 0;
margin-bottom: 0;
border-radius: 10px;
}
#custom-menu {
font-size: 16pt;
background-color: white;
color: #002635;
padding-left: 15px;
padding-right: 22px;
margin-left: 0;
margin-right: 10px;
margin-top: 0;
margin-bottom: 0;
border-radius: 10px;
}
'';
};
} }

View File

@ -19,7 +19,14 @@
./common/optional/desktop/waybar.nix ./common/optional/desktop/waybar.nix
]; ];
monitors = [
home.packages = [
pkgs.kitty
pkgs.zathura
pkgs.xfce.thunar
];
monitors = [
{ {
name = "Virtual-1"; name = "Virtual-1";
width = 2048; width = 2048;
@ -35,5 +42,5 @@ monitors = [
refreshRate = 60; refreshRate = 60;
x = 2048; x = 2048;
} }
]; ];
} }

View File

@ -3,17 +3,11 @@
{ {
home.username = "sam"; home.username = "sam";
home.homeDirectory = "/home/sam"; home.homeDirectory = "/home/sam";
home.stateVersion = "23.11"; home.stateVersion = "23.11";
imports = [ imports = [
] ++ (builtins.attrValues outputs.homeManagerModules); # import all homeManagerModules? ] ++ (builtins.attrValues outputs.homeManagerModules); # import all homeManagerModules?
home.packages = [
pkgs.kitty
pkgs.zathura
pkgs.xfce.thunar
];
home.file = { home.file = {
".icons/bibata".source = "${pkgs.bibata-cursors}/share/icons/Bibata-Modern-Classic"; ".icons/bibata".source = "${pkgs.bibata-cursors}/share/icons/Bibata-Modern-Classic";
}; };
@ -32,13 +26,13 @@
]; ];
gtk.enable = true; gtk.enable = true;
gtk.cursorTheme.package = pkgs.bibata-cursors; gtk.cursorTheme.package = pkgs.bibata-cursors;
gtk.cursorTheme.name = "Bibata-Modern-Ice"; gtk.cursorTheme.name = "Bibata-Modern-Ice";
gtk.theme.package = pkgs.gruvbox-gtk-theme; gtk.theme.package = pkgs.gruvbox-gtk-theme;
gtk.theme.name = "Gruvbox-Dark-B"; gtk.theme.name = "Gruvbox-Dark-B";
gtk.iconTheme.package = pkgs.gruvbox-plus-icons; gtk.iconTheme.package = pkgs.gruvbox-plus-icons;
gtk.iconTheme.name = "GruvboxPlus"; gtk.iconTheme.name = "GruvboxPlus";
@ -56,4 +50,3 @@
}; };
} }

View File

@ -6,7 +6,7 @@ let
secretsDirectory = builtins.toString inputs.nix-secrets; secretsDirectory = builtins.toString inputs.nix-secrets;
secretsFile = "${secretsDirectory}/secrets.yaml"; secretsFile = "${secretsDirectory}/secrets.yaml";
username = "sam"; username = "sam";
in in
{ {
users.users.${username} = { users.users.${username} = {
isNormalUser = true; isNormalUser = true;
@ -47,5 +47,5 @@ in
}; };
environment.systemPackages = [ environment.systemPackages = [
]; ];
} }

View File

@ -5,12 +5,13 @@ let
dev = "/dev/vda"; # depends on target hardware dev = "/dev/vda"; # depends on target hardware
encrypted = true; # currrently only applies to btrfs encrypted = true; # currrently only applies to btrfs
btrfsMountDevice = if encrypted then "/dev/mapper/crypted" else "/dev/root_vg/root"; btrfsMountDevice = if encrypted then "/dev/mapper/crypted" else "/dev/root_vg/root";
user = "sam";
in in
{ {
imports = imports =
[ [
# Create users for this host # Create users for this host
../common/users/sam ../common/users/${user}
# Disk configuration # Disk configuration
inputs.disko.nixosModules.disko inputs.disko.nixosModules.disko
@ -43,7 +44,7 @@ in
environment.persistence."/persist" = { environment.persistence."/persist" = {
hideMounts = true; hideMounts = true;
users.sam= { users.${user} = {
directories = [ directories = [
"Sync" "Sync"
"Keep" "Keep"

View File

@ -1,10 +1,4 @@
{ {
#fonts = import ./fonts.nix; #fonts = import ./fonts.nix;
monitors = import ./monitors.nix; monitors = import ./monitors.nix;
# pass-secret-service = import ./pass-secret-service.nix;
# rgbdaemon = import ./rgbdaemon.nix;
# shellcolor = import ./shellcolor.nix;
# wallpaper = import ./wallpaper.nix;
# xpo = import ./xpo.nix;
# colors = import ./colors.nix;
} }