waybar ricing and alacritty transparency
This commit is contained in:
parent
bd8fbdacd0
commit
f60f4bee7a
|
@ -8,7 +8,7 @@
|
||||||
dimInactive = true;
|
dimInactive = true;
|
||||||
terminalColors = true;
|
terminalColors = true;
|
||||||
theme = "wave";
|
theme = "wave";
|
||||||
transparent = false;
|
transparent = true;
|
||||||
undercurl = true;
|
undercurl = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,4 @@
|
||||||
{ config, pkgs, lib, ... }:
|
{ config, pkgs, ... }:
|
||||||
let
|
|
||||||
user = config.home.username;
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
programs.alacritty = {
|
programs.alacritty = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -38,10 +35,14 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
window.padding = {
|
window = {
|
||||||
|
padding = {
|
||||||
x = 5;
|
x = 5;
|
||||||
y = 5;
|
y = 5;
|
||||||
};
|
};
|
||||||
|
blur = true;
|
||||||
|
opacity = 0.9;
|
||||||
|
};
|
||||||
|
|
||||||
shell.program = "${pkgs.zsh}/bin/zsh";
|
shell.program = "${pkgs.zsh}/bin/zsh";
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
{
|
{ lib
|
||||||
lib,
|
, config
|
||||||
config,
|
, pkgs
|
||||||
pkgs,
|
, ...
|
||||||
...
|
|
||||||
}: {
|
}: {
|
||||||
|
|
||||||
imports = [
|
imports = [
|
||||||
|
@ -12,7 +11,7 @@
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
systemd = {
|
systemd = {
|
||||||
variables = ["--all"];
|
variables = [ "--all" ];
|
||||||
enable = true;
|
enable = true;
|
||||||
# Same as default, but stop graphical-session too
|
# Same as default, but stop graphical-session too
|
||||||
extraCommands = lib.mkBefore [
|
extraCommands = lib.mkBefore [
|
||||||
|
@ -25,7 +24,8 @@
|
||||||
monitor = "${toString (builtins.map (m: "monitor=${ m.name },${ toString( m.width ) }x${ toString( m.height ) }@${ toString( m.refreshRate ) },${ toString( m.x ) }x${ toString( m.y ) },${ toString( m.scale ) }\n") config.monitors)}";
|
monitor = "${toString (builtins.map (m: "monitor=${ m.name },${ toString( m.width ) }x${ toString( m.height ) }@${ toString( m.refreshRate ) },${ toString( m.x ) }x${ toString( m.y ) },${ toString( m.scale ) }\n") config.monitors)}";
|
||||||
active = "rgba(${config.colorScheme.colors.base08}ee)";
|
active = "rgba(${config.colorScheme.colors.base08}ee)";
|
||||||
inactive = "rgba(${config.colorScheme.colors.base0C}ee)";
|
inactive = "rgba(${config.colorScheme.colors.base0C}ee)";
|
||||||
in ''
|
in
|
||||||
|
''
|
||||||
|
|
||||||
${monitor}
|
${monitor}
|
||||||
$terminal = alacritty
|
$terminal = alacritty
|
||||||
|
@ -155,7 +155,7 @@
|
||||||
bindm = $mainMod, mouse:272, movewindow
|
bindm = $mainMod, mouse:272, movewindow
|
||||||
bindm = $mainMod, mouse:273, resizewindow
|
bindm = $mainMod, mouse:273, resizewindow
|
||||||
|
|
||||||
exec-once=bash ~/.config/hypr/start.sh
|
exec-once=swww-wallpaper-changer
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,37 +1,19 @@
|
||||||
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
pkgs,
|
home.packages = with pkgs; [
|
||||||
...
|
(writeShellScriptBin "swww-wallpaper-changer" ''
|
||||||
}:
|
|
||||||
{
|
|
||||||
systemd.user.services.wallpaper-changer = {
|
|
||||||
Unit = {
|
|
||||||
Description = "Script to change wallpaper using swww";
|
|
||||||
PartOf = [ "hyprland-session.target" ];
|
|
||||||
After = [ "hyprland-session.target" ]; # or "wayland.target", depending on your system setup
|
|
||||||
};
|
|
||||||
Install = {
|
|
||||||
WantedBy = [ "default.target" ];
|
|
||||||
};
|
|
||||||
Service = {
|
|
||||||
Type = [ "simple" ];
|
|
||||||
ExecStart = "${pkgs.writeShellScript "swww-wallpaper-changer" ''
|
|
||||||
export WAYLAND_DISPLAY="wayland-1"
|
export WAYLAND_DISPLAY="wayland-1"
|
||||||
wallpaper_dir="$HOME/.local/share/bg/"
|
wallpaper_dir="$HOME/.local/share/bg/"
|
||||||
[ -d "$wallpaper_dir" ] || mkdir -p "$wallpaper_dir"
|
[ -d "$wallpaper_dir" ] || mkdir -p "$wallpaper_dir"
|
||||||
|
${swww}/bin/swww-daemon &
|
||||||
# Allow some time for desktop to start
|
|
||||||
sleep 3
|
|
||||||
echo "starting daemon..."
|
|
||||||
${pkgs.swww}/bin/swww-daemon &
|
|
||||||
|
|
||||||
while true; do
|
while true; do
|
||||||
find "$wallpaper_dir" -type f -follow \( -iname \*.jpg -o -iname \*.png -o -iname \*.gif -o -iname \*.bmp \) | shuf | while read -r file; do
|
find "$wallpaper_dir" -type f -follow \( -iname \*.jpg -o -iname \*.png -o -iname \*.gif -o -iname \*.bmp \) | shuf | while read -r file; do
|
||||||
${pkgs.swww}/bin/swww img "$file" --transition-step 10 --transition-fps 60
|
${swww}/bin/swww img "$file" --transition-step 10 --transition-fps 60
|
||||||
[ $? != 0 ] && echo "swww failed, reloading daemon" && ${pkgs.swww}/bin/swww-daemon &
|
[ $? != 0 ] && echo "swww failed, exiting" && exit 1
|
||||||
sleep 600
|
sleep 600
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
''}";
|
'')
|
||||||
};
|
];
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
{
|
{ lib
|
||||||
lib,
|
, config
|
||||||
config,
|
, pkgs
|
||||||
pkgs,
|
, ...
|
||||||
...
|
|
||||||
}: {
|
}: {
|
||||||
# Let it try to start a few more times
|
# Let it try to start a few more times
|
||||||
systemd.user.services.waybar = {
|
systemd.user.services.waybar = {
|
||||||
|
@ -20,10 +19,14 @@
|
||||||
spacing = 5;
|
spacing = 5;
|
||||||
modules-left = [
|
modules-left = [
|
||||||
"custom/menu"
|
"custom/menu"
|
||||||
"wlr/workspaces"];
|
"hyprland/workspaces"
|
||||||
|
"hyprland/window"
|
||||||
|
];
|
||||||
|
|
||||||
modules-center = [
|
modules-center = [
|
||||||
"clock"
|
"clock"
|
||||||
];
|
];
|
||||||
|
|
||||||
modules-right = [
|
modules-right = [
|
||||||
"cpu"
|
"cpu"
|
||||||
"memory"
|
"memory"
|
||||||
|
@ -33,32 +36,40 @@
|
||||||
"tray"
|
"tray"
|
||||||
"custom/exit"
|
"custom/exit"
|
||||||
"custom/hostname"
|
"custom/hostname"
|
||||||
|
"custom/ip"
|
||||||
];
|
];
|
||||||
"wlr/workspaces" = {
|
|
||||||
"format" = "{icon}";
|
"hyprland/window" = {
|
||||||
|
"format" = "{}";
|
||||||
|
"rewrite" = {
|
||||||
|
"(.*) — Mozilla Firefox" = "$1";
|
||||||
|
};
|
||||||
|
"separate-outputs" = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
"hyprland/workspaces" = {
|
||||||
|
"format" = "{name}";
|
||||||
"on-click" = "activate";
|
"on-click" = "activate";
|
||||||
"format-icons"= {
|
"format-icons" = {
|
||||||
"1" = "";
|
"urgent" = "";
|
||||||
"2" = "";
|
"active" = "";
|
||||||
"3" = "";
|
"default" = "";
|
||||||
"4" = "";
|
|
||||||
"5" = "";
|
|
||||||
"urgent" = "";
|
|
||||||
"active" = "";
|
|
||||||
"default" = "";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
"clock" = {
|
"clock" = {
|
||||||
"format" = "<span> </span>{:%m/%d %H:%M}";
|
"format" = "<span> </span>{:%y-%m-%d %H:%M:%S}";
|
||||||
"tooltip-format" = "<big>{:%B %Y}</big>\n<tt><small>{calendar}</small></tt>";
|
"tooltip-format" = "<big>{:%B %Y}</big>\n<tt><small>{calendar}</small></tt>";
|
||||||
"on-click" = "calendar";
|
"on-click" = "calendar";
|
||||||
};
|
};
|
||||||
"cpu"= {
|
|
||||||
|
"cpu" = {
|
||||||
"interval" = 10;
|
"interval" = 10;
|
||||||
"format" = " {}%";
|
"format" = " {}%";
|
||||||
"max-length" = 10;
|
"max-length" = 10;
|
||||||
"on-click" = "";
|
"on-click" = "";
|
||||||
};
|
};
|
||||||
|
|
||||||
"memory" = {
|
"memory" = {
|
||||||
"interval" = 30;
|
"interval" = 30;
|
||||||
"format" = " {}%";
|
"format" = " {}%";
|
||||||
|
@ -68,9 +79,8 @@
|
||||||
|
|
||||||
"network" = {
|
"network" = {
|
||||||
"format-wifi" = "直 {signalStrength}%";
|
"format-wifi" = "直 {signalStrength}%";
|
||||||
"format-ethernet" = " wired";
|
"format-ethernet" = " wired ({ipaddr})";
|
||||||
"format-disconnected" = "睊";
|
"format-disconnected" = "睊";
|
||||||
"on-click" = "bash ~/.config/waybar/scripts/rofi-wifi-menu.sh";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
"battery" = {
|
"battery" = {
|
||||||
|
@ -89,7 +99,7 @@
|
||||||
"format-plugged" = " {capacity}%";
|
"format-plugged" = " {capacity}%";
|
||||||
"format-alt" = "{icon} {time}";
|
"format-alt" = "{icon} {time}";
|
||||||
"format-full" = " {capacity}%";
|
"format-full" = " {capacity}%";
|
||||||
"format-icons" = [" " " " " " " " " "];
|
"format-icons" = [ " " " " " " " " " " ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"tray" = {
|
"tray" = {
|
||||||
|
@ -97,13 +107,13 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
"custom/menu" = {
|
"custom/menu" = {
|
||||||
"format" = "";
|
"format" = " Nixos";
|
||||||
"on-click" = "rofi -show drun";
|
"on-click" = "wofi --show drun";
|
||||||
};
|
};
|
||||||
|
|
||||||
"custom/hostname" = {
|
"custom/hostname" = {
|
||||||
"exec" = "echo $USER@$(hostname)";
|
"exec" = "echo $USER@$(hostname)";
|
||||||
"on-click" = "alacritty";
|
"on-click" = "$TERMINAL";
|
||||||
};
|
};
|
||||||
|
|
||||||
"custom/exit" = {
|
"custom/exit" = {
|
||||||
|
|
|
@ -1,16 +1,15 @@
|
||||||
{ pkgs ? import <nixpkgs> { }, stdenv, fetchFromGitHub }:
|
{ pkgs ? import <nixpkgs> { }, fetchFromGitHub }:
|
||||||
pkgs.stdenv.mkDerivation rec {
|
pkgs.stdenv.mkDerivation {
|
||||||
pname = "sddm-theme";
|
pname = "sddm-theme";
|
||||||
version = "1.6";
|
version = "1.6";
|
||||||
dontBuild = true;
|
dontBuild = true;
|
||||||
# nativeBuildInputs = with pkgs; [
|
|
||||||
# sddm
|
|
||||||
# ];
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
mkdir -p $out/share/sddm/themes
|
mkdir -p $out/share/sddm/themes
|
||||||
cp -aR $src $out/share/sddm/themes/sugar-candy
|
cp -aR $src $out/share/sddm/themes/sugar-candy
|
||||||
touch $out/share/sddm/themes/balls
|
touch $out/share/sddm/themes/balls
|
||||||
'';
|
'';
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "Kangie";
|
owner = "Kangie";
|
||||||
repo = "sddm-sugar-candy";
|
repo = "sddm-sugar-candy";
|
||||||
|
|
Loading…
Reference in New Issue