Compare commits

...
Sign in to create a new pull request.

6 commits

Author SHA1 Message Date
c683fb2571 sticking to plasma for a little longer 2025-02-06 21:41:48 -03:00
259a0b6118 Further steps to a usable hyprland session 2025-02-06 00:49:23 -03:00
b602e3ec1b fast animations, some other changes 2025-02-05 11:37:27 -03:00
78b6eaf05c added packages to hyprland 2025-02-05 10:11:29 -03:00
01589b30ad I'll com back to this every once in a while. I need a vertical panel 2025-02-05 00:24:19 -03:00
6291136770 this will eventually be the hyprland config.
once hyprpanel has a vertical layout, imma bounce from plasma
2025-02-03 18:08:06 -03:00
7 changed files with 398 additions and 14 deletions

91
flake.lock generated
View file

@ -237,6 +237,24 @@
"type": "github" "type": "github"
} }
}, },
"flake-utils_3": {
"inputs": {
"systems": "systems_5"
},
"locked": {
"lastModified": 1726560853,
"narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "c1dfcf08411b08f6b8615f7d8971a2bfa81d5e8a",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"fromYaml": { "fromYaml": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -402,6 +420,27 @@
"type": "github" "type": "github"
} }
}, },
"home-manager_4": {
"inputs": {
"nixpkgs": [
"tritanium-shell",
"nixpkgs"
]
},
"locked": {
"lastModified": 1730837930,
"narHash": "sha256-0kZL4m+bKBJUBQse0HanewWO0g8hDdCvBhudzxgehqc=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "2f607e07f3ac7e53541120536708e824acccfaa8",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"homepage": { "homepage": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -561,15 +600,15 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1736798957, "lastModified": 1730785428,
"narHash": "sha256-qwpCtZhSsSNQtK4xYGzMiyEDhkNzOCz/Vfu4oL2ETsQ=", "narHash": "sha256-Zwl8YgTVJTEum+L+0zVAWvXAGbWAuXHax3KzuejaDyo=",
"owner": "NixOS", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "9abb87b552b7f55ac8916b6fc9e5cb486656a2f3", "rev": "4aa36568d413aca0ea84a1684d2d46f55dbabad7",
"type": "github" "type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "owner": "nixos",
"ref": "nixos-unstable", "ref": "nixos-unstable",
"repo": "nixpkgs", "repo": "nixpkgs",
"type": "github" "type": "github"
@ -589,7 +628,8 @@
"nixos-generators": "nixos-generators", "nixos-generators": "nixos-generators",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"nixpkgs-stable": "nixpkgs-stable", "nixpkgs-stable": "nixpkgs-stable",
"stylix": "stylix" "stylix": "stylix",
"tritanium-shell": "tritanium-shell"
} }
}, },
"stylix": { "stylix": {
@ -604,7 +644,9 @@
"git-hooks": "git-hooks", "git-hooks": "git-hooks",
"gnome-shell": "gnome-shell", "gnome-shell": "gnome-shell",
"home-manager": "home-manager_3", "home-manager": "home-manager_3",
"nixpkgs": "nixpkgs_2", "nixpkgs": [
"nixpkgs-stable"
],
"systems": "systems_4", "systems": "systems_4",
"tinted-foot": "tinted-foot", "tinted-foot": "tinted-foot",
"tinted-kitty": "tinted-kitty", "tinted-kitty": "tinted-kitty",
@ -685,6 +727,21 @@
"type": "github" "type": "github"
} }
}, },
"systems_5": {
"locked": {
"lastModified": 1689347949,
"narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=",
"owner": "nix-systems",
"repo": "default-linux",
"rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default-linux",
"type": "github"
}
},
"tinted-foot": { "tinted-foot": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -751,6 +808,26 @@
"type": "github" "type": "github"
} }
}, },
"tritanium-shell": {
"inputs": {
"flake-utils": "flake-utils_3",
"home-manager": "home-manager_4",
"nixpkgs": "nixpkgs_2"
},
"locked": {
"lastModified": 1738888826,
"narHash": "sha256-xjUMyq7fTidbTwVqKEZ16SZSKECNx7mVDFicQswuZh8=",
"owner": "baduhai",
"repo": "tritanium-shell",
"rev": "d788a288ffc49847849d691824c2f46999b9b864",
"type": "github"
},
"original": {
"owner": "baduhai",
"repo": "tritanium-shell",
"type": "github"
}
},
"utils": { "utils": {
"inputs": { "inputs": {
"systems": "systems_2" "systems": "systems_2"

View file

@ -48,8 +48,12 @@
inputs.nixpkgs.follows = "nixpkgs-stable"; inputs.nixpkgs.follows = "nixpkgs-stable";
}; };
stylix.url = "github:danth/stylix"; stylix = {
url = "github:danth/stylix";
inputs.nixpkgs.follows = "nixpkgs-stable";
};
tritanium-shell.url = "github:baduhai/tritanium-shell";
}; };
outputs = outputs =
@ -68,6 +72,7 @@
nix-minecraft, nix-minecraft,
nixos-generators, nixos-generators,
stylix, stylix,
tritanium-shell,
... ...
}: }:
{ {

View file

@ -1,10 +1,15 @@
{ ... }: { inputs, ... }:
{ {
home-manager = { home-manager = {
useGlobalPkgs = true; useGlobalPkgs = true;
useUserPackages = true; useUserPackages = true;
backupFileExtension = "bkp"; backupFileExtension = "bkp";
users.user = import ../../../users/desktops/user.nix; users.user = {
imports = [
../../../users/desktops/user.nix
inputs.tritanium-shell.homeManagerModules.default
];
};
}; };
} }

View file

@ -1,4 +1,4 @@
{ inputs, pkgs, ... }: { pkgs, ... }:
let let
kdepkgs = with pkgs.kdePackages; [ kdepkgs = with pkgs.kdePackages; [
ark ark
@ -30,7 +30,6 @@ in
aspellDicts.en-computers aspellDicts.en-computers
aspellDicts.pt_BR aspellDicts.pt_BR
bat bat
bitwarden-desktop
clonehero clonehero
deploy-rs deploy-rs
distrobox distrobox
@ -38,6 +37,7 @@ in
firefox firefox
freecad-wayland freecad-wayland
fzf fzf
ghostty
gimp gimp
heroic heroic
inkscape inkscape
@ -103,6 +103,7 @@ in
kdeconnect.enable = true; kdeconnect.enable = true;
partition-manager.enable = true; partition-manager.enable = true;
gamemode.enable = true; gamemode.enable = true;
hyprland.enable = true;
nix-index-database.comma.enable = true; nix-index-database.comma.enable = true;
appimage = { appimage = {
enable = true; enable = true;
@ -120,6 +121,7 @@ in
corefonts corefonts
noto-fonts-cjk-sans noto-fonts-cjk-sans
roboto roboto
nerd-fonts.jetbrains-mono
]; ];
}; };

View file

@ -4,8 +4,8 @@
stylix = { stylix = {
enable = true; enable = true;
image = pkgs.fetchurl { image = pkgs.fetchurl {
url = "https://images.unsplash.com/photo-1701453831008-ea11046da960?ixlib=rb-4.0.3&q=85&fm=jpg&crop=entropy&cs=srgb&dl=nat-uN9OSpSsw4A-unsplash.jpg"; url = "https://w.wallhaven.cc/full/dp/wallhaven-dpwvl3.jpg";
sha256 = "sha256-89o5VYI4cMP/O33oCaHi61hUYmIWEdyr8uGf/b2DMUk="; sha256 = "sha256-h9UeYj8jSRgSv8XL+zgds4KtooLlJ+IqwxZbQEXdCh4=";
}; };
base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-mocha.yaml"; base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-mocha.yaml";
cursor = { cursor = {

View file

@ -3,5 +3,6 @@
{ {
imports = [ imports = [
./programs.nix ./programs.nix
./hyprland.nix
]; ];
} }

View file

@ -0,0 +1,294 @@
{ lib, pkgs, ... }:
let
heightfittr = pkgs.writeShellApplication {
name = "heightfittr";
runtimeInputs = with pkgs; [
socat
hyprland
];
text = ''
function handle {
case "$1" in
*openwindow*)
hyprctl dispatch scroller:fitheight all > /dev/null
;;
*closewindow*)
hyprctl dispatch scroller:fitheight all > /dev/null
;;
esac
}
socat - "UNIX-CONNECT:$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock" | while read -r line; do
handle "$line"
done
'';
};
scrollermodetoggle = pkgs.writeShellApplication {
name = "scrollermodetoggle";
runtimeInputs = with pkgs; [ hyprland ];
text = ''
if [ -f "$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/colmode" ]; then
rm "$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/colmode"
hyprctl --batch 'dispatch scroller:setmode row; notify 2 1000 0 "Row Mode"'
else
touch "$XDG_RUNTIME_DIR/hypr/$HYPRLAND_INSTANCE_SIGNATURE/colmode"
hyprctl --batch 'dispatch scroller:setmode col; notify 2 1000 0 "Column Mode"'
fi
'';
};
in
{
wayland.windowManager.hyprland = {
enable = true;
plugins = with pkgs.hyprlandPlugins; [ hyprscroller ];
extraConfig = ''
################
### MONITORS ###
################
monitor=,preferred,auto,auto
#################
### AUTOSTART ###
#################
exec-once = ulauncher --hide-window
exec-once = ${lib.getExe heightfittr}
env = XCURSOR_SIZE,24
env = HYPRCURSOR_SIZE,24
#####################
### LOOK AND FEEL ###
#####################
general {
gaps_in = 5
gaps_out = 20
border_size = 2
resize_on_border = true
allow_tearing = false
layout = scroller
}
misc {
font_family = Inter
}
plugin {
scroller {
column_default_width = onethird
focuswrap = false
column_widths = onethird onehalf twothirds
center_row_if_space_available = true
}
}
decoration {
rounding = 10
rounding_power = 2
dim_inactive = true
dim_strength = 0.3
shadow {
enabled = true
range = 4
render_power = 3
}
blur {
enabled = true
size = 8
passes = 1
vibrancy = 0.1696
}
}
animations {
enabled = yes, please :)
bezier = easeOutQuint,0.23,1,0.32,1
bezier = easeInOutCubic,0.65,0.05,0.36,1
bezier = linear,0,0,1,1
bezier = almostLinear,0.5,0.5,0.75,1.0
bezier = quick,0.15,0,0.1,1
animation = global, 1, 1, default
animation = border, 1, 1, easeOutQuint
animation = windows, 1, 1, easeOutQuint
animation = windowsIn, 1, 1, easeOutQuint, popin 87%
animation = windowsOut, 1, 1, linear, popin 87%
animation = fadeIn, 1, 1, almostLinear
animation = fadeOut, 1, 1, almostLinear
animation = fade, 1, 1, quick
animation = layers, 1, 1, easeOutQuint
animation = layersIn, 1, 1, easeOutQuint, fade
animation = layersOut, 1, 1, linear, fade
animation = fadeLayersIn, 1, 1, almostLinear
animation = fadeLayersOut, 1, 1, almostLinear
animation = workspaces, 1, 1, almostLinear, slidevert
}
misc {
force_default_wallpaper = 0
disable_hyprland_logo = true
}
#############
### INPUT ###
#############
input {
kb_layout = us
kb_variant = altgr-intl
follow_mouse = 1
sensitivity = 0
accel_profile = flat
natural_scroll = true
touchpad {
natural_scroll = true
clickfinger_behavior = true
}
}
###################
### KEYBINDINGS ###
###################
$mainMod = SUPER
$terminal = ghostty
$menu = ulauncher-toggle
# APP SHORTCUTS
bind = ALT, SPACE, exec, $menu
bind = $mainMod, RETURN, exec, $terminal
# SESSION MANAGEMENT
bind = CTRL ALT, DELETE, exit,
bind = $mainMod, mouse_up, exec, hyprnome
bind = $mainMod, mouse_down, exec, hyprnome --previous
bind = CTRL ALT, j, exec, hyprnome
bind = CTRL ALT, k, exec, hyprnome --previous
bind = $mainMod CTRL ALT, j, exec, hyprnome --move
bind = $mainMod CTRL ALT, k, exec, hyprnome --move --previous
bindel = ,XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+
bindel = ,XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-
bindel = ,XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle
bindel = ,XF86AudioMicMute, exec, wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle
bindel = ,XF86MonBrightnessUp, exec, brightnessctl s 10%+
bindel = ,XF86MonBrightnessDown, exec, brightnessctl s 10%-
bindl = , XF86AudioNext, exec, playerctl next
bindl = , XF86AudioPause, exec, playerctl play-pause
bindl = , XF86AudioPlay, exec, playerctl play-pause
bindl = , XF86AudioPrev, exec, playerctl previous
bind = CTRL ALT SHIFT, a, exec, bash /home/user/.local/bin/toggle-audio-output.sh
# WINDOW MANAGEMENT
bind = ALT, F4, killactive,
bind = $mainMod, space, togglefloating,
bind = $mainMod, f, fullscreen
bindm = $mainMod, mouse:272, movewindow
bindm = $mainMod, mouse:273, resizewindow
bind = SUPER, h, movefocus, l
bind = SUPER, l, movefocus, r
bind = SUPER, k, movefocus, u
bind = SUPER, j, movefocus, d
bind = $mainMod CTRL, h, movewindow, l
bind = $mainMod CTRL, l, movewindow, r
bind = $mainMod CTRL, k, movewindow, u
bind = $mainMod CTRL, j, movewindow, d
bind = $mainMod, v, exec, ${lib.getExe scrollermodetoggle}
bind = $mainMod, r, scroller:cyclewidth, next
bind = $mainMod CTRL, r, scroller:cyclewidth, prev
bind = $mainMod, p, scroller:pin,
bind = $mainMod, c, scroller:alignwindow, center
bind = $mainMod CTRL, f, scroller:fitsize, all
####################
### WINDOW RULES ###
####################
windowrulev2 = suppressevent maximize, class:.*
windowrulev2 = nofocus,class:^$,title:^$,xwayland:1,floating:1,fullscreen:0,pinned:0
# ulauncher
windowrule = float, ulauncher
windowrule = pin, ulauncher
windowrule = noborder, ulauncher
windowrule = noshadow, ulauncher
windowrule = nomaxsize, ulauncher
windowrule = noblur, ulauncher
windowrulev2 = animation slide top, class:^(ulauncher)$
# firefox
windowrulev2 = plugin:scroller:columnwidth onehalf, class:(firefox)
'';
};
services = {
tritanium-shell = {
enable = true;
integrations.hyprland.enable = true;
settings = {
vertical = true;
animations.activeWorkspace = "smooth";
minWorkspaces = 1;
lockCommand = "hyprlock";
bar.modules.workspacesIndicator.reverseScrollDirection = true;
};
};
swaync = {
enable = true;
settings = {
positionX = "left";
positionY = "top";
layer = "overlay";
control-center-layer = "top";
layer-shell = true;
cssPriority = "application";
control-center-margin-top = 20;
control-center-margin-bottom = 20;
control-center-margin-right = 20;
control-center-margin-left = 20;
notification-2fa-action = true;
notification-inline-replies = false;
notification-icon-size = 64;
notification-body-image-height = 100;
notification-body-image-width = 200;
timeout = 10;
timeout-low = 5;
timeout-critical = 0;
fit-to-screen = true;
relative-timestamps = true;
control-center-width = 500;
control-center-height = 600;
notification-window-width = 500;
keyboard-shortcuts = true;
image-visibility = "when-available";
transition-time = 200;
hide-on-clear = false;
hide-on-action = true;
script-fail-notify = true;
widgets = [
"inhibitors"
"title"
"dnd"
"notifications"
"mpris"
];
widget-config = {
inhibitors = {
text = "Inhibitors";
button-text = "Clear All";
clear-all-button = true;
};
title = {
text = "Notifications";
clear-all-button = true;
button-text = "Clear All";
};
dnd = {
text = "Do Not Disturb";
};
mpris = {
image-size = 96;
image-radius = 12;
};
};
};
};
};
programs = {
hyprlock.enable = true;
};
home.packages = with pkgs; [
brightnessctl
hyprnome
playerctl
swaynotificationcenter
ulauncher
];
}