Systemd-ify Waybar, move aliases to individualized places, more Sway and Jovian changes
This commit is contained in:
parent
949cb85b2b
commit
d257cd9bf5
14 changed files with 212 additions and 143 deletions
42
flake.lock
generated
42
flake.lock
generated
|
@ -171,6 +171,24 @@
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems"
|
"systems": "systems"
|
||||||
},
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1731533236,
|
||||||
|
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"flake-utils_2": {
|
||||||
|
"inputs": {
|
||||||
|
"systems": "systems_2"
|
||||||
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1710146030,
|
"lastModified": 1710146030,
|
||||||
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
|
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
|
||||||
|
@ -185,9 +203,9 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"flake-utils_2": {
|
"flake-utils_3": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"systems": "systems_2"
|
"systems": "systems_3"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731533236,
|
"lastModified": 1731533236,
|
||||||
|
@ -287,7 +305,7 @@
|
||||||
"crane": "crane",
|
"crane": "crane",
|
||||||
"flake-compat": "flake-compat",
|
"flake-compat": "flake-compat",
|
||||||
"flake-parts": "flake-parts",
|
"flake-parts": "flake-parts",
|
||||||
"flake-utils": "flake-utils",
|
"flake-utils": "flake-utils_2",
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"stable"
|
"stable"
|
||||||
],
|
],
|
||||||
|
@ -336,7 +354,7 @@
|
||||||
"minecraft": {
|
"minecraft": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat_3",
|
"flake-compat": "flake-compat_3",
|
||||||
"flake-utils": "flake-utils_2",
|
"flake-utils": "flake-utils_3",
|
||||||
"nixpkgs": "nixpkgs_2"
|
"nixpkgs": "nixpkgs_2"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
|
@ -490,6 +508,7 @@
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"blender": "blender",
|
"blender": "blender",
|
||||||
"disko": "disko",
|
"disko": "disko",
|
||||||
|
"flake-utils": "flake-utils",
|
||||||
"hm": "hm",
|
"hm": "hm",
|
||||||
"impermanence": "impermanence",
|
"impermanence": "impermanence",
|
||||||
"jovian": "jovian",
|
"jovian": "jovian",
|
||||||
|
@ -571,6 +590,21 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"systems_3": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681028828,
|
||||||
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"treefmt-nix": {
|
"treefmt-nix": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
|
|
58
flake.nix
58
flake.nix
|
@ -4,6 +4,9 @@
|
||||||
stable.url = "nixpkgs/nixos-24.11";
|
stable.url = "nixpkgs/nixos-24.11";
|
||||||
unstable.url = "nixpkgs/nixos-unstable";
|
unstable.url = "nixpkgs/nixos-unstable";
|
||||||
|
|
||||||
|
# Flake helpers
|
||||||
|
flake-utils.url = "github:numtide/flake-utils";
|
||||||
|
|
||||||
# System inputs
|
# System inputs
|
||||||
disko = {
|
disko = {
|
||||||
url = "github:nix-community/disko";
|
url = "github:nix-community/disko";
|
||||||
|
@ -48,6 +51,8 @@
|
||||||
stable,
|
stable,
|
||||||
unstable,
|
unstable,
|
||||||
|
|
||||||
|
flake-utils,
|
||||||
|
|
||||||
disko,
|
disko,
|
||||||
impermanence,
|
impermanence,
|
||||||
lanzaboote,
|
lanzaboote,
|
||||||
|
@ -63,34 +68,31 @@
|
||||||
...
|
...
|
||||||
}@inputs:
|
}@inputs:
|
||||||
|
|
||||||
let
|
inputs.flake-utils.lib.eachDefaultSystemPassThrough (system:
|
||||||
mkNix = modules: channel: channel.lib.nixosSystem {
|
let
|
||||||
inherit modules;
|
mkNix = modules: channel: channel.lib.nixosSystem {
|
||||||
specialArgs = inputs;
|
inherit modules;
|
||||||
};
|
specialArgs = inputs;
|
||||||
mkHome = modules: channel: arch: hm.lib.homeManagerConfiguration {
|
};
|
||||||
inherit modules;
|
mkHome = modules: channel: hm.lib.homeManagerConfiguration {
|
||||||
pkgs = builtins.getAttr arch channel.legacyPackages;
|
inherit modules;
|
||||||
extraSpecialArgs = inputs;
|
pkgs = channel.legacyPackages.${system};
|
||||||
};
|
extraSpecialArgs = inputs;
|
||||||
in {
|
};
|
||||||
# nh os switch /path -H host
|
in {
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
tower = mkNix [ ./hosts/tower ] stable; # Main Desktop
|
tower = mkNix [ ./hosts/tower ] stable;
|
||||||
|
|
||||||
intuos = mkNix [ ./hosts/intuos ] stable; # Wacom Intuos Tablet
|
intuos = mkNix [ ./hosts/intuos ] stable;
|
||||||
jupiter = mkNix [ ./hosts/jupiter ] unstable; # Steam Deck
|
jupiter = mkNix [ ./hosts/jupiter ] unstable;
|
||||||
redmond = mkNix [ ./hosts/redmond ] stable; # Lenovo Dual-Boot
|
redmond = mkNix [ ./hosts/redmond ] stable;
|
||||||
|
|
||||||
midas = mkNix [ ./hosts/midas ] stable; # Dell Optiplex 5040
|
midas = mkNix [ ./hosts/midas ] stable;
|
||||||
kitty = mkNix [ ./hosts/kitty ] stable; # Dell Optiplex 7010
|
kitty = mkNix [ ./hosts/kitty ] stable;
|
||||||
prophet = mkNix [ ./hosts/prophet ] stable; # Oracle Neoverse-N1
|
prophet = mkNix [ ./hosts/prophet ] stable;
|
||||||
};
|
};
|
||||||
|
|
||||||
# nh home switch /path -c arch
|
homeConfigurations.bun = mkHome [ ./modules/home ] stable;
|
||||||
homeConfigurations = {
|
}
|
||||||
x86 = mkHome [ ./modules/home ] stable "x86_64-linux";
|
);
|
||||||
aarch = mkHome [ ./modules/home ] stable "aarch64-linux";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -24,11 +24,7 @@
|
||||||
|
|
||||||
boot.kernelPackages = lib.mkForce pkgs.linuxPackages_jovian;
|
boot.kernelPackages = lib.mkForce pkgs.linuxPackages_jovian;
|
||||||
|
|
||||||
programs.steam = {
|
programs.steam.extest.enable = true;
|
||||||
extest.enable = true;
|
|
||||||
localNetworkGameTransfers.openFirewall = true;
|
|
||||||
remotePlay.openFirewall = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
keyd.enable = lib.mkForce false;
|
keyd.enable = lib.mkForce false;
|
||||||
|
@ -36,6 +32,8 @@
|
||||||
xserver.desktopManager.gnome.enable = true;
|
xserver.desktopManager.gnome.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
hardware.xone.enable = true;
|
||||||
|
|
||||||
networking = {
|
networking = {
|
||||||
networkmanager.enable = true;
|
networkmanager.enable = true;
|
||||||
wireless.enable = lib.mkForce false;
|
wireless.enable = lib.mkForce false;
|
||||||
|
@ -94,6 +92,7 @@
|
||||||
"steam-jupiter-unwrapped"
|
"steam-jupiter-unwrapped"
|
||||||
"steamdeck-firmware"
|
"steamdeck-firmware"
|
||||||
"steamdeck-hw-theme"
|
"steamdeck-hw-theme"
|
||||||
|
"xow_dongle-firmware"
|
||||||
];
|
];
|
||||||
|
|
||||||
specialisation.desktop.configuration.config.system.steamdeck.enable = lib.mkForce false;
|
specialisation.desktop.configuration.config.system.steamdeck.enable = lib.mkForce false;
|
||||||
|
|
|
@ -8,6 +8,9 @@
|
||||||
remmina
|
remmina
|
||||||
teams-for-linux
|
teams-for-linux
|
||||||
];
|
];
|
||||||
|
|
||||||
|
shellAliases.seneca = "ssh jhampton1@matrix.senecapolytechnic.ca";
|
||||||
|
|
||||||
persistence."/persist${config.home.homeDirectory}".directories = [
|
persistence."/persist${config.home.homeDirectory}".directories = [
|
||||||
".cache/gpclient"
|
".cache/gpclient"
|
||||||
".config/com.yuezk.qt"
|
".config/com.yuezk.qt"
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
{ ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
programs.direnv = {
|
programs.direnv = {
|
||||||
enable = true;
|
enable = true;
|
||||||
nix-direnv.enable = true;
|
nix-direnv.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
home.persistence."/persist${config.home.homeDirectory}".directories = [ ".local/share/direnv" ];
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,10 @@
|
||||||
{
|
{
|
||||||
programs.fastfetch.enable = true;
|
programs.fastfetch.enable = true;
|
||||||
|
|
||||||
home.packages = with pkgs; [ (writeScriptBin "smallfetch" "fastfetch --config ~/.config/fastfetch/small.jsonc") ];
|
home = {
|
||||||
|
shellAliases.ff = "clear && fastfetch";
|
||||||
|
packages = with pkgs; [ (writeScriptBin "smallfetch" "fastfetch --config ~/.config/fastfetch/small.jsonc") ];
|
||||||
|
};
|
||||||
|
|
||||||
xdg.configFile."fastfetch".source = ./configs;
|
xdg.configFile."fastfetch".source = ./configs;
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,4 +4,9 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
flake = "${config.home.homeDirectory}/Projects/nixos-config";
|
flake = "${config.home.homeDirectory}/Projects/nixos-config";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
home.shellAliases = {
|
||||||
|
nhs = "nh os switch";
|
||||||
|
nht = "nh os test";
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,12 +2,10 @@
|
||||||
{
|
{
|
||||||
home.shellAliases = {
|
home.shellAliases = {
|
||||||
# NixOS
|
# NixOS
|
||||||
nhs = "nh os switch";
|
|
||||||
nixclean = "nix store gc; nix store optimise";
|
nixclean = "nix store gc; nix store optimise";
|
||||||
nixpurge = "sudo nix-collect-garbage --delete-old";
|
nixpurge = "sudo nix-collect-garbage --delete-old";
|
||||||
|
|
||||||
# Shortcuts
|
# Shortcuts
|
||||||
ff = "clear && fastfetch";
|
|
||||||
myip = "curl ifconfig.co";
|
myip = "curl ifconfig.co";
|
||||||
seneca = "ssh jhampton1@matrix.senecapolytechnic.ca";
|
seneca = "ssh jhampton1@matrix.senecapolytechnic.ca";
|
||||||
};
|
};
|
||||||
|
|
|
@ -2,10 +2,10 @@
|
||||||
{
|
{
|
||||||
home.packages = lib.mkIf config.home.desktop.enable (with pkgsStable; [
|
home.packages = lib.mkIf config.home.desktop.enable (with pkgsStable; [
|
||||||
liberation_ttf
|
liberation_ttf
|
||||||
twitter-color-emoji
|
|
||||||
noto-fonts
|
noto-fonts
|
||||||
sarasa-gothic
|
sarasa-gothic
|
||||||
ubuntu_font_family
|
twitter-color-emoji
|
||||||
|
ubuntu-classic
|
||||||
(nerdfonts.override { fonts = [ "UbuntuMono" ]; })
|
(nerdfonts.override { fonts = [ "UbuntuMono" ]; })
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,18 +2,26 @@
|
||||||
{
|
{
|
||||||
home.packages = with pkgs; lib.mkIf config.programs.rofi.enable [
|
home.packages = with pkgs; lib.mkIf config.programs.rofi.enable [
|
||||||
(writeScriptBin "rofiscratch" ''
|
(writeScriptBin "rofiscratch" ''
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
SCRATCHPADS=$(echo -e "Btop\nMusic\nSound\nEasyEffects" | rofi -dmenu -i -p "Scratchpads")
|
SCRATCHPADS=$(echo -e "Btop\nMusic\nSound\nEasyEffects" | rofi -dmenu -i -p "Scratchpads")
|
||||||
|
|
||||||
case $SCRATCHPADS in
|
case $SCRATCHPADS in
|
||||||
Btop) foot -a btop -T Btop btop;;
|
Btop) foot -a btop -T Btop btop;;
|
||||||
Music) foot -a music -T Music ncmpcpp;;
|
Music) foot -a music -T Music ncmpcpp;;
|
||||||
Sound) foot -a sound -T Sound pulsemixer;;
|
Sound) foot -a sound -T Sound pulsemixer;;
|
||||||
esac
|
esac
|
||||||
'')
|
'')
|
||||||
|
|
||||||
(writeScriptBin "rofipower" ''
|
(writeScriptBin "rofipower" ''
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
POWER=$(echo -e "Shutdown\nReboot\nLock\nSleep\nKill" | rofi -dmenu -i -p "Power")
|
POWER=$(echo -e "Shutdown\nReboot\nLock\nSleep\nKill" | rofi -dmenu -i -p "Power")
|
||||||
|
|
||||||
case $POWER in
|
case $POWER in
|
||||||
Shutdown) poweroff;;
|
Shutdown) poweroff;;
|
||||||
Reboot) reboot;;
|
Reboot) reboot;;
|
||||||
|
Lock) swaylock;;
|
||||||
Sleep) systemctl suspend;;
|
Sleep) systemctl suspend;;
|
||||||
Kill) pkill -9 $XDG_CURRENT_DESKTOP;;
|
Kill) pkill -9 $XDG_CURRENT_DESKTOP;;
|
||||||
esac
|
esac
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
pulseModule = {
|
pulseModule = with pkgs; {
|
||||||
format = "{icon} {volume}%";
|
format = "{icon} {volume}%";
|
||||||
format-bluetooth = "{icon} {volume}%";
|
format-bluetooth = "{icon} {volume}%";
|
||||||
format-muted = " muted";
|
format-muted = " muted";
|
||||||
|
@ -33,9 +33,9 @@
|
||||||
" "
|
" "
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
on-click = "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
on-click = "${wireplumber}/bin/wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
||||||
on-click-middle = "wpctl set-volume @DEFAULT_AUDIO_SINK@ 100%";
|
on-click-middle = "${wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 100%";
|
||||||
on-click-right = "wpctl set-volume @DEFAULT_AUDIO_SINK@ 60%";
|
on-click-right = "${wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 60%";
|
||||||
ignored-sinks = [ "Easy Effects Sink" ];
|
ignored-sinks = [ "Easy Effects Sink" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -52,32 +52,42 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
vramModule = {
|
vramModule = {
|
||||||
exec = pkgs.writeScript "vramScript" ''
|
exec = with pkgs; pkgs.writeScript "vramScript.sh" ''
|
||||||
# Don't run the script if running on integrated graphics
|
#!/bin/sh
|
||||||
gpu_driver=$(${pkgs.pciutils}/bin/lspci -k | grep -Eo "in use: (nvidia|amdgpu)" | awk '{print $3}')
|
|
||||||
|
|
||||||
if [ -n "$gpu_driver" ]; then
|
LSPCI="${pciutils}/bin/lspci"
|
||||||
if [ "$gpu_driver" == "nvidia" ]; then
|
GREP="${gnugrep}/bin/grep"
|
||||||
vram_usage_mb=$(nvidia-smi --query-gpu=memory.used --format=csv,noheader,nounits)
|
AWK="${gawk}/bin/awk"
|
||||||
temperature=$(nvidia-smi --query-gpu=temperature.gpu --format=csv,noheader,nounits)
|
BC="${bc}/bin/bc"
|
||||||
|
HEAD="${uutils-coreutils-noprefix}/bin/head"
|
||||||
|
CAT="${uutils-coreutils-noprefix}/bin/cat"
|
||||||
|
|
||||||
elif [ "$gpu_driver" == "amdgpu" ]; then
|
# Detect the active GPU driver
|
||||||
vram_usage_mb=$(echo "$(cat /sys/class/drm/card0/device/mem_info_vram_used || cat /sys/class/drm/card1/device/mem_info_vram_used) / 1024 / 1024" | bc)
|
gpu_driver="$($LSPCI -k | $GREP -Eo 'in use: (nvidia|amdgpu)' | $AWK '{print $3}')"
|
||||||
temperature=$(${pkgs.lm_sensors}/bin/sensors | grep 'edge' | awk '{print $2}' | sed 's/[^0-9.-]//g')
|
|
||||||
fi
|
# Exit if no supported GPU driver is in use
|
||||||
|
if [[ -z "$gpu_driver" ]]; then
|
||||||
# Check if VRAM usage is under 1GB
|
exit 0
|
||||||
if [ $vram_usage_mb -lt 1024 ]; then
|
|
||||||
vram_usage_display="$(echo $vram_usage_mb)M"
|
|
||||||
else
|
|
||||||
# Convert MB to GiB
|
|
||||||
vram_usage_gib=$(bc <<< "scale=2; $vram_usage_mb / 1024")
|
|
||||||
vram_usage_display="$(echo $vram_usage_gib)G"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Print the VRAM usage and temperature
|
|
||||||
echo "{\"text\":\" $(echo $vram_usage_display)\",\"tooltip\":\"$(echo $temperature)°C\"}"
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Get VRAM usage in MB
|
||||||
|
if [[ "$gpu_driver" == "nvidia" ]]; then
|
||||||
|
vram_usage_mb="$(nvidia-smi --query-gpu=memory.used --format=csv,noheader,nounits | $HEAD -n1)"
|
||||||
|
elif [[ "$gpu_driver" == "amdgpu" ]]; then
|
||||||
|
vram_bytes="$($CAT /sys/class/drm/card*/device/mem_info_vram_used 2>/dev/null | $HEAD -n1)"
|
||||||
|
vram_usage_mb="$($BC <<< "$vram_bytes / 1024 / 1024")"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Format VRAM usage for display
|
||||||
|
if [[ "$vram_usage_mb" -lt 1024 ]]; then
|
||||||
|
vram_usage_display="''${vram_usage_mb}M"
|
||||||
|
else
|
||||||
|
vram_usage_gib="$($BC <<< "scale=2; $vram_usage_mb / 1024")"
|
||||||
|
vram_usage_display="''${vram_usage_gib}G"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Output the VRAM usage
|
||||||
|
echo "{\"text\": \" ''${vram_usage_display}\"}"
|
||||||
'';
|
'';
|
||||||
format = "{}";
|
format = "{}";
|
||||||
return-type = "json";
|
return-type = "json";
|
||||||
|
@ -94,6 +104,7 @@
|
||||||
# Misc
|
# Misc
|
||||||
trayModule.spacing = 5;
|
trayModule.spacing = 5;
|
||||||
|
|
||||||
|
# Wireless
|
||||||
networkModule = {
|
networkModule = {
|
||||||
format-ethernet = "";
|
format-ethernet = "";
|
||||||
format-wifi = "";
|
format-wifi = "";
|
||||||
|
@ -144,21 +155,28 @@
|
||||||
icon-size = 15;
|
icon-size = 15;
|
||||||
};
|
};
|
||||||
|
|
||||||
mpdModule = {
|
mprisModule = {
|
||||||
|
player = "mpd";
|
||||||
format = " {title}";
|
format = " {title}";
|
||||||
format-paused = " {artist}";
|
format-paused = " {artist}";
|
||||||
format-stopped = "";
|
format-stopped = "";
|
||||||
format-disconnected = "";
|
tooltip-format = lib.concatStrings [
|
||||||
tooltip-format = "{artist} - {title}";
|
"{title} - {artist} - {album}\n"
|
||||||
|
"{position}/{length}"
|
||||||
|
];
|
||||||
interval = 2;
|
interval = 2;
|
||||||
max-length = 30;
|
max-length = 30;
|
||||||
on-click = "playerctl -p mpd play-pause";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
notificationModule = {
|
notificationModule = with pkgs; {
|
||||||
exec = pkgs.writeScript "notificationScript" ''
|
exec = pkgs.writeScript "notificationScript.sh" ''
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
SED="${gnused}/bin/sed"
|
||||||
|
MAKOCTL="${mako}/bin/makoctl"
|
||||||
|
|
||||||
# Extract the second line after "default"
|
# Extract the second line after "default"
|
||||||
mode=$(echo "$(makoctl mode)" | sed -n '/default/{n;p}')
|
mode=$(echo "$($MAKOCTL mode)" | $SED -n '/default/{n;p}')
|
||||||
|
|
||||||
# Print the notification status with the tooltip
|
# Print the notification status with the tooltip
|
||||||
if [[ "$mode" == "do-not-disturb" ]]; then
|
if [[ "$mode" == "do-not-disturb" ]]; then
|
||||||
|
@ -170,7 +188,17 @@
|
||||||
format = "{}";
|
format = "{}";
|
||||||
return-type = "json";
|
return-type = "json";
|
||||||
interval = 2;
|
interval = 2;
|
||||||
on-click = "makotoggle";
|
on-click = "${mako}/bin/makoctl mode -t do-not-disturb";
|
||||||
|
};
|
||||||
|
|
||||||
|
idleModule = {
|
||||||
|
format = "{icon}";
|
||||||
|
format-icons = {
|
||||||
|
activated = " On";
|
||||||
|
deactivated = " Off";
|
||||||
|
tooltip-format-activated = "Sleep inhibited.";
|
||||||
|
tooltip-format-deactivated = "Sleep uninhibited.";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
weatherModule = {
|
weatherModule = {
|
||||||
|
@ -208,6 +236,7 @@
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
enable = config.home.desktop.enable;
|
enable = config.home.desktop.enable;
|
||||||
|
systemd.enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
displayPrimary = {
|
displayPrimary = {
|
||||||
name = "bar1";
|
name = "bar1";
|
||||||
|
@ -225,9 +254,10 @@
|
||||||
];
|
];
|
||||||
modules-right = [
|
modules-right = [
|
||||||
"pulseaudio"
|
"pulseaudio"
|
||||||
"mpd"
|
"mpris"
|
||||||
"custom/notifs"
|
"custom/notifs"
|
||||||
"custom/weather2"
|
"idle_inhibitor"
|
||||||
|
"custom/weather"
|
||||||
"cpu"
|
"cpu"
|
||||||
"memory"
|
"memory"
|
||||||
"custom/vram"
|
"custom/vram"
|
||||||
|
@ -244,9 +274,10 @@
|
||||||
"sway/workspaces" = workspaceModule;
|
"sway/workspaces" = workspaceModule;
|
||||||
"sway/window" = windowModule;
|
"sway/window" = windowModule;
|
||||||
"pulseaudio" = pulseModule;
|
"pulseaudio" = pulseModule;
|
||||||
"mpd" = mpdModule;
|
"mpris" = mprisModule;
|
||||||
"custom/notifs" = notificationModule;
|
"custom/notifs" = notificationModule;
|
||||||
"custom/weather2" = weatherModule;
|
"idle_inhibitor" = idleModule;
|
||||||
|
"custom/weather" = weatherModule;
|
||||||
"cpu" = cpuModule;
|
"cpu" = cpuModule;
|
||||||
"memory" = ramModule;
|
"memory" = ramModule;
|
||||||
"custom/vram" = vramModule;
|
"custom/vram" = vramModule;
|
||||||
|
@ -283,8 +314,6 @@
|
||||||
"sway/workspaces" = workspaceModule;
|
"sway/workspaces" = workspaceModule;
|
||||||
"sway/window" = windowModule;
|
"sway/window" = windowModule;
|
||||||
"pulseaudio" = pulseModule;
|
"pulseaudio" = pulseModule;
|
||||||
"mpd" = mpdModule;
|
|
||||||
"custom/notifs" = notificationModule;
|
|
||||||
"cpu" = cpuModule;
|
"cpu" = cpuModule;
|
||||||
"memory" = ramModule;
|
"memory" = ramModule;
|
||||||
"custom/vram" = vramModule;
|
"custom/vram" = vramModule;
|
||||||
|
@ -297,7 +326,7 @@
|
||||||
border: 0;
|
border: 0;
|
||||||
border-radius: 0;
|
border-radius: 0;
|
||||||
min-height: 0;
|
min-height: 0;
|
||||||
font-family: ${config.look.fonts.main}, ${config.look.fonts.mono};
|
font-family: ${config.look.fonts.main}, ${config.look.fonts.mono};
|
||||||
font-size: 15.5px;
|
font-size: 15.5px;
|
||||||
color: #${config.look.colors.text};
|
color: #${config.look.colors.text};
|
||||||
}
|
}
|
||||||
|
@ -313,9 +342,6 @@
|
||||||
#network {
|
#network {
|
||||||
padding: 0 10px 0 4px;
|
padding: 0 10px 0 4px;
|
||||||
}
|
}
|
||||||
#network.disconnected,#bluetooth.off {
|
|
||||||
color: #424242;
|
|
||||||
}
|
|
||||||
#bluetooth {
|
#bluetooth {
|
||||||
margin: 0 6px 0 4px;
|
margin: 0 6px 0 4px;
|
||||||
font-size: 13.4px;
|
font-size: 13.4px;
|
||||||
|
@ -337,17 +363,34 @@
|
||||||
box-shadow: none;
|
box-shadow: none;
|
||||||
background: #${config.look.colors.light};
|
background: #${config.look.colors.light};
|
||||||
}
|
}
|
||||||
#scratchpad {
|
#scratchpad, #privacy {
|
||||||
margin-left: 4px;
|
margin-left: 4px;
|
||||||
}
|
}
|
||||||
#privacy {
|
#mpris, #custom-notifs, #idle_inhibitor, #custom-weather, #cpu, #memory, #custom-vram, #backlight, #battery {
|
||||||
margin-left: 4px;
|
|
||||||
}
|
|
||||||
#cpu, #memory, #custom-vram, #mpd, #backlight, #battery, #custom-weather, #custom-weather2, #custom-notifs {
|
|
||||||
margin: 0 5px 0 2px;
|
margin: 0 5px 0 2px;
|
||||||
}
|
}
|
||||||
#clock {
|
#pulseaudio {
|
||||||
margin: 0 2px 0 2px;
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#mpris.paused, #custom-notifs.disabled, #idle_inhibitor.deactivated {
|
||||||
|
color: #888;
|
||||||
|
}
|
||||||
|
#pulseaudio.muted, #network.disconnected, #bluetooth.off {
|
||||||
|
color: #424242;
|
||||||
|
}
|
||||||
|
|
||||||
|
#mpris {
|
||||||
|
border-bottom: 3px solid #ffb066;
|
||||||
|
}
|
||||||
|
#custom-notifs {
|
||||||
|
border-bottom: 3px solid #3823C4;
|
||||||
|
}
|
||||||
|
#idle_inhibitor {
|
||||||
|
border-bottom: 3px solid #941efc;
|
||||||
|
}
|
||||||
|
#custom-weather {
|
||||||
|
border-bottom: 3px solid #c75bd3;
|
||||||
}
|
}
|
||||||
#cpu {
|
#cpu {
|
||||||
border-bottom: 3px solid #f90000;
|
border-bottom: 3px solid #f90000;
|
||||||
|
@ -358,38 +401,15 @@
|
||||||
#custom-vram {
|
#custom-vram {
|
||||||
border-bottom: 3px solid #33FF00;
|
border-bottom: 3px solid #33FF00;
|
||||||
}
|
}
|
||||||
#mpd {
|
|
||||||
border-bottom: 3px solid #ffb066;
|
|
||||||
}
|
|
||||||
#mpd.paused {
|
|
||||||
color: #888;
|
|
||||||
}
|
|
||||||
#clock {
|
|
||||||
border-bottom: 3px solid #0a6cf5;
|
|
||||||
}
|
|
||||||
#backlight {
|
#backlight {
|
||||||
border-bottom: 3px solid #5ffca3;
|
border-bottom: 3px solid #5ffca3;
|
||||||
}
|
}
|
||||||
#battery {
|
#battery {
|
||||||
border-bottom: 3px solid #fcfc16;
|
border-bottom: 3px solid #fcfc16;
|
||||||
}
|
}
|
||||||
#custom-weather {
|
#clock {
|
||||||
border-bottom: 3px solid #3823C4;
|
border-bottom: 3px solid #0a6cf5;
|
||||||
}
|
margin: 0 2px 0 2px;
|
||||||
#custom-weather2 {
|
|
||||||
border-bottom: 3px solid #c75bd3;
|
|
||||||
}
|
|
||||||
#custom-notifs {
|
|
||||||
border-bottom: 3px solid #3823C4;
|
|
||||||
}
|
|
||||||
#custom-notifs.disabled {
|
|
||||||
color: #888;
|
|
||||||
}
|
|
||||||
#pulseaudio {
|
|
||||||
margin-right: 5px;
|
|
||||||
}
|
|
||||||
#pulseaudio.muted {
|
|
||||||
color: #424242;
|
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,24 +1,17 @@
|
||||||
{ ... }:
|
{ ... }:
|
||||||
{
|
{
|
||||||
wayland.windowManager.sway.config = {
|
wayland.windowManager.sway.config.startup = [
|
||||||
bars = [{ command = "waybar"; }];
|
# Scratchpads
|
||||||
|
{ command = "foot -a btop -T Gotop btop"; }
|
||||||
|
{ command = "foot -a music -T Music ncmpcpp"; }
|
||||||
|
{ command = "foot -a sound -T Sound pulsemixer"; }
|
||||||
|
|
||||||
startup = [
|
# Daemons and tray
|
||||||
# Scratchpads
|
{ command = "kanshictl reload"; always = true; }
|
||||||
{ command = "foot -a btop -T Gotop btop"; }
|
{ command = "wayland-pipewire-idle-inhibit"; }
|
||||||
{ command = "foot -a music -T Music ncmpcpp"; }
|
|
||||||
{ command = "foot -a sound -T Sound pulsemixer"; }
|
|
||||||
|
|
||||||
# Daemons and tray
|
# Foreground
|
||||||
{
|
{ command = "thunderbird"; }
|
||||||
command = "kanshictl reload";
|
{ command = "vesktop"; }
|
||||||
always = true;
|
];
|
||||||
}
|
|
||||||
{ command = "wayland-pipewire-idle-inhibit"; }
|
|
||||||
|
|
||||||
# Foreground
|
|
||||||
{ command = "thunderbird"; }
|
|
||||||
{ command = "vesktop"; }
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,11 +38,11 @@
|
||||||
(assign "${config.displays.tower1}" workspaces1) ++
|
(assign "${config.displays.tower1}" workspaces1) ++
|
||||||
(assign "${config.displays.tower2}" workspaces2) ++
|
(assign "${config.displays.tower2}" workspaces2) ++
|
||||||
(assign "${config.displays.tower3}" workspaces3) ++
|
(assign "${config.displays.tower3}" workspaces3) ++
|
||||||
(assign "${config.displays.tower3}" workspaces4) ++
|
(assign "${config.displays.tower4}" workspaces4) ++
|
||||||
|
|
||||||
(assign "${config.displays.estradiol1}" workspaces1) ++
|
(assign "${config.displays.estradiol1}" workspaces1) ++
|
||||||
(assign "${config.displays.estradiol1}" workspaces2) ++
|
(assign "${config.displays.estradiol1}" workspaces2) ++
|
||||||
(assign "${config.displays.estradiol1}" workspaces4) ++
|
(assign "${config.displays.estradiol2}" workspaces3) ++
|
||||||
(assign "${config.displays.estradiol2}" workspaces3);
|
(assign "${config.displays.estradiol2}" workspaces4);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,6 +32,8 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
bars = [ ];
|
||||||
|
|
||||||
fonts = {
|
fonts = {
|
||||||
names = [ config.look.fonts.main ];
|
names = [ config.look.fonts.main ];
|
||||||
size = 10.5;
|
size = 10.5;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue