sway on nvidia + ironbar
This commit is contained in:
parent
362d12714c
commit
481e682fbf
16 changed files with 830 additions and 655 deletions
392
home/home.nix
392
home/home.nix
|
@ -10,17 +10,17 @@
|
|||
palette-hex = pkgs.lib.nix-rice.palette.toRgbHex pkgs.rice.palette;
|
||||
palette-shex = pkgs.lib.nix-rice.palette.toRGBShortHex pkgs.rice.palette;
|
||||
in {
|
||||
imports = [
|
||||
inputs.hyprland.homeManagerModules.default
|
||||
./programs/eww/default.nix
|
||||
];
|
||||
|
||||
home.stateVersion = "22.11";
|
||||
|
||||
imports = [
|
||||
inputs.ironbar.homeManagerModules.default
|
||||
# ./programs/eww/default.nix
|
||||
];
|
||||
|
||||
home.packages = with pkgs;
|
||||
[
|
||||
thunderbird
|
||||
clementine
|
||||
strawberry
|
||||
inkscape
|
||||
xfce.thunar
|
||||
feh
|
||||
|
@ -40,7 +40,6 @@ in {
|
|||
slurp
|
||||
swaybg
|
||||
wlogout
|
||||
wf-recorder
|
||||
libnotify
|
||||
xorg.xrdb
|
||||
swayidle
|
||||
|
@ -51,17 +50,14 @@ in {
|
|||
kooha
|
||||
nyxt
|
||||
|
||||
xplr
|
||||
culr
|
||||
swayosd
|
||||
fuzzel
|
||||
|
||||
kdeconnect
|
||||
# syncthing
|
||||
keepassxc
|
||||
git-credential-keepassxc
|
||||
|
||||
|
||||
direnv
|
||||
|
||||
mpv
|
||||
|
@ -88,43 +84,229 @@ in {
|
|||
|
||||
services.udiskie.enable = true;
|
||||
|
||||
wayland.windowManager.hyprland = {
|
||||
programs.ironbar = with pkgs.rice; {
|
||||
enable = true;
|
||||
systemdIntegration = true;
|
||||
nvidiaPatches = true;
|
||||
xwayland = {
|
||||
enable = true;
|
||||
hidpi = false;
|
||||
config = {
|
||||
anchor_to_edges = true;
|
||||
position = "top";
|
||||
height = fonts.sans.size;
|
||||
icon_theme = icons.name;
|
||||
|
||||
start = [
|
||||
{ type = "workspaces"; all_monitors = true; }
|
||||
{ type = "sys_info";
|
||||
interval.memory = 30;
|
||||
interval.cpu = 1;
|
||||
format = [
|
||||
" {cpu_percent}%"
|
||||
" {memory_used} / {memory_total} GB"
|
||||
];
|
||||
}
|
||||
];
|
||||
center = [
|
||||
{ type = "focused"; icon_size = 12; }
|
||||
];
|
||||
end = [
|
||||
{ type = "music";
|
||||
player_type = "mpris";
|
||||
|
||||
on_click_middle = "playerctl play-pause";
|
||||
on_scroll_up = "playerctl volume +5";
|
||||
on_scroll_down = "playerctl volume -5";
|
||||
}
|
||||
{ type = "clock"; }
|
||||
];
|
||||
};
|
||||
recommendedEnvironment = true;
|
||||
extraConfig = with pkgs.rice; (builtins.replaceStrings
|
||||
style = with palette-hex; (builtins.replaceStrings
|
||||
[
|
||||
"#BGIMAGE"
|
||||
"#GTKTHEME"
|
||||
"#FONT"
|
||||
"#ICONTHEME"
|
||||
"#ACTIVEBORDER"
|
||||
"#BG"
|
||||
"#DARKBG"
|
||||
"#BORDER"
|
||||
"#THICK"
|
||||
"#ROUND"
|
||||
"#GAPSIN"
|
||||
"#GAPSOUT"
|
||||
"#ACTIVEBORDER"
|
||||
"#TEXT"
|
||||
"#URGENT"
|
||||
"#FONT"
|
||||
"#SZFONT"
|
||||
]
|
||||
[
|
||||
"${bg.image}"
|
||||
gtk-theme.name
|
||||
util.bg
|
||||
normal.black
|
||||
normal.yellow
|
||||
bright.yellow
|
||||
util.fg
|
||||
normal.red
|
||||
fonts.sans.name
|
||||
icons.name
|
||||
palette-shex.bright.yellow
|
||||
palette-shex.util.bg
|
||||
(builtins.toString borders.thickness)
|
||||
(builtins.toString borders.rounding)
|
||||
(builtins.toString borders.gaps_in)
|
||||
(builtins.toString borders.gaps_out)
|
||||
(builtins.toString fonts.sans.size)
|
||||
]
|
||||
(builtins.readFile dots/hyprland/hyprland.conf));
|
||||
(builtins.readFile dots/ironbar.css));
|
||||
};
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
package = pkgs.sway;
|
||||
config = with pkgs.rice; {
|
||||
bars = [];
|
||||
# reintroduces flicker
|
||||
# output = {
|
||||
# "*" = {
|
||||
# adaptive_sync = "on";
|
||||
# };
|
||||
# };
|
||||
focus = {
|
||||
mouseWarping = "container";
|
||||
wrapping = "no";
|
||||
};
|
||||
fonts = with fonts; {
|
||||
names = [sans.name emoji.name];
|
||||
size = 10.0;
|
||||
};
|
||||
gaps = {
|
||||
inner = borders.gaps_in;
|
||||
outer = borders.gaps_out;
|
||||
smartGaps = true;
|
||||
smartBorders = "no_gaps";
|
||||
};
|
||||
window = {
|
||||
border = borders.thickness;
|
||||
hideEdgeBorders = "smart";
|
||||
titlebar = false;
|
||||
};
|
||||
workspaceAutoBackAndForth = false;
|
||||
input = {
|
||||
"*" = {
|
||||
accel_profile = "flat";
|
||||
pointer_accel = "0.0";
|
||||
xkb_options = "caps:escape";
|
||||
};
|
||||
};
|
||||
startup = [
|
||||
{command = "mullvad connect";}
|
||||
{command = "swaybg -i $HOME/.nix/wallpaper.png -m fill";}
|
||||
{command = "ckb-next -c -b";}
|
||||
{command = "xrdb -l ~/.Xresources";}
|
||||
{command = "swayosd --max-volume 100";}
|
||||
{command = "keepassxc";}
|
||||
{command = "swaync";}
|
||||
];
|
||||
terminal = "kitty";
|
||||
modifier = "Mod4";
|
||||
keybindings = {
|
||||
"Mod4+Return" = "exec kitty";
|
||||
"Mod4+d" = "exec fuzzel";
|
||||
"Mod4+e" = "exec thunar";
|
||||
"Mod4+f" = "exec firefox";
|
||||
"Mod4+Shift+e" = "exec wlogout";
|
||||
"Mod4+n" = "exec swaync-client -t";
|
||||
"Mod4+Space" = "floating toggle; move absolute position center";
|
||||
"Mod4+c" = "focus floating; move absolute position center";
|
||||
"Mod4+Shift+Space" = "fullscreen toggle";
|
||||
"Mod4+a" = "focus parent";
|
||||
"Mod4+Shift+a" = "focus child";
|
||||
"Mod4+h" = "focus left";
|
||||
"Mod4+j" = "focus down";
|
||||
"Mod4+k" = "focus up";
|
||||
"Mod4+l" = "focus right";
|
||||
"Mod4+Shift+h" = "move left";
|
||||
"Mod4+Shift+j" = "move down";
|
||||
"Mod4+Shift+k" = "move up";
|
||||
"Mod4+Shift+l" = "move right";
|
||||
"Mod4+1" = "workspace 1";
|
||||
"Mod4+Shift+1" = "move container to workspace 1";
|
||||
"Mod4+2" = "workspace 2";
|
||||
"Mod4+Shift+2" = "move container to workspace 2";
|
||||
"Mod4+3" = "workspace 3";
|
||||
"Mod4+Shift+3" = "move container to workspace 3";
|
||||
"Mod4+4" = "workspace 4";
|
||||
"Mod4+Shift+4" = "move container to workspace 4";
|
||||
"Mod4+r" = "mode resize";
|
||||
"Mod4+Shift+minus" = "move scratchpad";
|
||||
"Mod4+minus" = "scratchpad show";
|
||||
"Mod4+Shift+q" = "kill";
|
||||
"Mod4+Shift+v" = "split horizontal";
|
||||
"Mod4+v" = "split vertical";
|
||||
"XF86AudioMute" = "exec swayosd --output-volume mute-toggle";
|
||||
"XF86AudioRaiseVolume" = "exec swayosd --output-volume raise";
|
||||
"XF86AudioLowerVolume" = "exec swayosd --output-volume lower";
|
||||
"XF86AudioStop" = "exec playerctl stop";
|
||||
"XF86AudioPlay" = "exec playerctl play-pause";
|
||||
"XF86AudioPrev" = "exec playerctl previous";
|
||||
"XF86AudioNext" = "exec playerctl next";
|
||||
};
|
||||
menu = "fuzzel";
|
||||
colors = with palette-hex; {
|
||||
background = util.bg;
|
||||
focused = {
|
||||
background = util.bg;
|
||||
border = bright.yellow;
|
||||
childBorder = bright.yellow;
|
||||
indicator = normal.blue;
|
||||
text = util.fg;
|
||||
};
|
||||
focusedInactive = {
|
||||
background = normal.black;
|
||||
border = normal.yellow;
|
||||
childBorder = normal.yellow;
|
||||
indicator = normal.blue;
|
||||
text = normal.white;
|
||||
};
|
||||
placeholder = {
|
||||
background = util.bg;
|
||||
border = bright.green;
|
||||
childBorder = bright.green;
|
||||
indicator = normal.blue;
|
||||
text = util.fg;
|
||||
};
|
||||
unfocused = {
|
||||
background = normal.black;
|
||||
border = util.bg;
|
||||
childBorder = util.bg;
|
||||
indicator = normal.blue;
|
||||
text = normal.white;
|
||||
};
|
||||
urgent = {
|
||||
background = normal.red;
|
||||
border = normal.red;
|
||||
childBorder = normal.red;
|
||||
indicator = normal.red;
|
||||
text = normal.blue;
|
||||
};
|
||||
};
|
||||
};
|
||||
systemd.enable = true;
|
||||
wrapperFeatures = {
|
||||
base = true;
|
||||
gtk = true;
|
||||
};
|
||||
xwayland = true;
|
||||
};
|
||||
|
||||
# extraConfig = with pkgs.rice; (builtins.replaceStrings
|
||||
# [
|
||||
# "#BGIMAGE"
|
||||
# "#GTKTHEME"
|
||||
# "#FONT"
|
||||
# "#ICONTHEME"
|
||||
# "#ACTIVEBORDER"
|
||||
# "#BORDER"
|
||||
# "#THICK"
|
||||
# "#ROUND"
|
||||
# "#GAPSIN"
|
||||
# "#GAPSOUT"
|
||||
# ]
|
||||
# [
|
||||
# "${bg.image}"
|
||||
# gtk-theme.name
|
||||
# fonts.sans.name
|
||||
# icons.name
|
||||
# palette-shex.bright.yellow
|
||||
# palette-shex.util.bg
|
||||
# (builtins.toString borders.thickness)
|
||||
# (builtins.toString borders.rounding)
|
||||
# (builtins.toString borders.gaps_in)
|
||||
# (builtins.toString borders.gaps_out)
|
||||
# ]
|
||||
# (builtins.readFile dots/hyprland/hyprland.conf));
|
||||
|
||||
programs.starship = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
@ -135,65 +317,54 @@ in {
|
|||
};
|
||||
};
|
||||
|
||||
programs.eww-hyprland = {
|
||||
enable = true;
|
||||
package = pkgs.eww-git;
|
||||
colors = with palette-hex; (builtins.replaceStrings
|
||||
[
|
||||
"#BLACK"
|
||||
"#BLCKA"
|
||||
"#RED"
|
||||
"#RDA"
|
||||
"#GREEN"
|
||||
"#GRNA"
|
||||
"#YELLOW"
|
||||
"#YLWA"
|
||||
"#BLUE"
|
||||
"#BLUA"
|
||||
"#MAGENTA"
|
||||
"#MGNA"
|
||||
"#CYAN"
|
||||
"#CYNA"
|
||||
"#WHITE"
|
||||
"#WHTA"
|
||||
"#FG"
|
||||
"#BG"
|
||||
]
|
||||
[
|
||||
normal.black
|
||||
bright.black
|
||||
normal.red
|
||||
bright.red
|
||||
normal.green
|
||||
bright.green
|
||||
normal.yellow
|
||||
bright.yellow
|
||||
normal.blue
|
||||
bright.blue
|
||||
normal.magenta
|
||||
bright.magenta
|
||||
normal.cyan
|
||||
bright.cyan
|
||||
normal.white
|
||||
bright.white
|
||||
util.fg
|
||||
util.bg
|
||||
] (builtins.readFile dots/eww/colors.scss));
|
||||
};
|
||||
|
||||
# programs.eww-custom = {
|
||||
# enable = true;
|
||||
# package = pkgs.eww-wayland;
|
||||
# colors = with palette-hex; (builtins.replaceStrings
|
||||
# [
|
||||
# "#BLACK"
|
||||
# "#BLCKA"
|
||||
# "#RED"
|
||||
# "#RDA"
|
||||
# "#GREEN"
|
||||
# "#GRNA"
|
||||
# "#YELLOW"
|
||||
# "#YLWA"
|
||||
# "#BLUE"
|
||||
# "#BLUA"
|
||||
# "#MAGENTA"
|
||||
# "#MGNA"
|
||||
# "#CYAN"
|
||||
# "#CYNA"
|
||||
# "#WHITE"
|
||||
# "#WHTA"
|
||||
# "#FG"
|
||||
# "#BG"
|
||||
# ]
|
||||
# [
|
||||
# normal.black
|
||||
# bright.black
|
||||
# normal.red
|
||||
# bright.red
|
||||
# normal.green
|
||||
# bright.green
|
||||
# normal.yellow
|
||||
# bright.yellow
|
||||
# normal.blue
|
||||
# bright.blue
|
||||
# normal.magenta
|
||||
# bright.magenta
|
||||
# normal.cyan
|
||||
# bright.cyan
|
||||
# normal.white
|
||||
# bright.white
|
||||
# util.fg
|
||||
# util.bg
|
||||
# ] (builtins.readFile dots/eww/colors.scss));
|
||||
# };
|
||||
|
||||
systemd.user.startServices = "sd-switch";
|
||||
systemd.user.services."hyprland-system76" = {
|
||||
Unit = {
|
||||
Description = "the hyprland process scheduler hook";
|
||||
Requires = ["dbus.service"];
|
||||
};
|
||||
Install = {
|
||||
WantedBy = ["graphical-session.target" "default.target"];
|
||||
};
|
||||
Service = {
|
||||
ExecStart = ''${pkgs.hyprland-system76-scheduler-integration}/bin/hyprland-system76-scheduler-hook.sh'';
|
||||
};
|
||||
};
|
||||
|
||||
xdg.enable = true;
|
||||
xresources.properties = with palette-hex; {
|
||||
|
@ -263,9 +434,6 @@ in {
|
|||
"${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}"
|
||||
];
|
||||
|
||||
# home.sessionVariables = {
|
||||
# GTK_THEME = pkgs.rice.gtk.name;
|
||||
# };
|
||||
programs.wlogout = {
|
||||
enable = true;
|
||||
layout = builtins.fromJSON (builtins.readFile dots/wlogout/layout);
|
||||
|
@ -556,24 +724,24 @@ in {
|
|||
editor.lsp.display-messages = true;
|
||||
};
|
||||
languages = {
|
||||
|
||||
language = [{
|
||||
name = "rust";
|
||||
config = {
|
||||
cargo = {
|
||||
buildScripts = {
|
||||
language = [
|
||||
{
|
||||
name = "rust";
|
||||
config = {
|
||||
cargo = {
|
||||
buildScripts = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
procMacro = {
|
||||
enable = true;
|
||||
};
|
||||
check = {
|
||||
command = "clippy"; # as i walk through the valley of the sha
|
||||
};
|
||||
};
|
||||
procMacro = {
|
||||
enable = true;
|
||||
};
|
||||
check = {
|
||||
command = "clippy"; # as i walk through the valley of the sha
|
||||
};
|
||||
};
|
||||
}];
|
||||
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue