refactor: move programs into graphical and shell
This commit is contained in:
parent
68047c894e
commit
727d197f41
39 changed files with 68 additions and 62 deletions
22
configs/graphical/ags.nix
Normal file
22
configs/graphical/ags.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{ inputs, pkgs, ... }:
|
||||
{
|
||||
home-manager.users.rafiq = {
|
||||
imports = [ inputs.ags.homeManagerModules.default ];
|
||||
|
||||
# Expose the cli tools to the home environment
|
||||
home.packages = [ inputs.ags.packages.${pkgs.stdenv.hostPlatform.system}.io ];
|
||||
|
||||
programs.ags = {
|
||||
enable = true;
|
||||
configDir = ./ags; # ~/.config/ags
|
||||
systemd.enable = false;
|
||||
|
||||
# The module only includes the core astal3, astal4 and astal-io libraries
|
||||
extraPackages = with pkgs; [
|
||||
# add packages to runtime
|
||||
# inputs.ags.packages.${pkgs.system}.battery
|
||||
# fzf
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
0
configs/graphical/ags/test
Normal file
0
configs/graphical/ags/test
Normal file
9
configs/graphical/clipse.nix
Normal file
9
configs/graphical/clipse.nix
Normal file
|
@ -0,0 +1,9 @@
|
|||
{
|
||||
home-manager.users.rafiq = {
|
||||
services.clipse = {
|
||||
enable = true;
|
||||
historySize = 1000;
|
||||
imageDisplay.type = "kitty";
|
||||
};
|
||||
};
|
||||
}
|
22
configs/graphical/default.nix
Normal file
22
configs/graphical/default.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{ pkgs, inputs, ... }:
|
||||
{
|
||||
imports = [
|
||||
./ags.nix
|
||||
./clipse.nix
|
||||
./dunst.nix
|
||||
./firefox.nix
|
||||
./fuzzel.nix
|
||||
./getty.nix
|
||||
./hyprland.nix
|
||||
./hyprlock.nix
|
||||
./hyprshade.nix
|
||||
./kitty.nix
|
||||
./spicetify.nix
|
||||
];
|
||||
|
||||
home-manager.users.rafiq.home.packages = with pkgs; [
|
||||
hyprpicker
|
||||
inputs.hyprcloser.packages.${pkgs.stdenv.hostPlatform.system}.default
|
||||
wl-clipboard # provides cli copy and paste commands
|
||||
];
|
||||
}
|
5
configs/graphical/dunst.nix
Normal file
5
configs/graphical/dunst.nix
Normal file
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
home-manager.users.rafiq = {
|
||||
services.dunst.enable = true;
|
||||
};
|
||||
}
|
7
configs/graphical/firefox.nix
Normal file
7
configs/graphical/firefox.nix
Normal file
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
home-manager.users.rafiq = {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
}
|
15
configs/graphical/fuzzel.nix
Normal file
15
configs/graphical/fuzzel.nix
Normal file
|
@ -0,0 +1,15 @@
|
|||
{
|
||||
home-manager.users.rafiq = {
|
||||
programs.fuzzel = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
terminal = "kitty -1 -e";
|
||||
layer = "top";
|
||||
keyboard-focus = "on-demand";
|
||||
list-executables-in-path = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
5
configs/graphical/getty.nix
Normal file
5
configs/graphical/getty.nix
Normal file
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
services.getty = {
|
||||
autologinUser = "rafiq";
|
||||
};
|
||||
}
|
135
configs/graphical/hyprland.nix
Normal file
135
configs/graphical/hyprland.nix
Normal file
|
@ -0,0 +1,135 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
programs.hyprland = {
|
||||
enable = true;
|
||||
package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
|
||||
portalPackage =
|
||||
inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland;
|
||||
};
|
||||
|
||||
home-manager.users.rafiq = {
|
||||
home.sessionVariables.NIXOS_OZONE_WL = "1";
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
package = null;
|
||||
portalPackage = null;
|
||||
settings = {
|
||||
"$mainMonitor" = "desc:OOO AN-270W04K";
|
||||
"$vertMonitor" = "desc:Philips Consumer Electronics Company PHL 246V5 AU11330000086";
|
||||
"$mainMod" = "SUPER";
|
||||
"$terminal" = "kitty -1";
|
||||
"$multiplexer" = "$terminal -e zellij";
|
||||
"$browser" = "firefox";
|
||||
"$music" = "spotify";
|
||||
"$launcher" = "fuzzel";
|
||||
"$clipboard" = "$terminal --class clipse -e clipse";
|
||||
|
||||
# Programs to run at startup
|
||||
exec-once = [
|
||||
"hyprlock"
|
||||
"clipse -listen"
|
||||
"hyprcloser"
|
||||
];
|
||||
|
||||
env = [
|
||||
"XCURSOR_SIZE,32"
|
||||
|
||||
# Nvidia Settings
|
||||
"LIBVA_DRIVER_NAME,nvidia"
|
||||
"__GLX_VENDOR_LIBRARY_NAME,nvidia"
|
||||
"NVD_BACKEND,direct # needed for running vaapi-driver on later drivers"
|
||||
];
|
||||
|
||||
# Monitors
|
||||
monitor = [
|
||||
"$mainMonitor, 3840x2160@60, auto, auto"
|
||||
"$vertMonitor, 1920x1080@60, auto-left, auto, transform, 3"
|
||||
", preferred, auto, 1"
|
||||
];
|
||||
|
||||
# Switching to the current workspace will switch to the previous
|
||||
binds.workspace_back_and_forth = true;
|
||||
cursor.default_monitor = "$mainMonitor";
|
||||
|
||||
# Windows
|
||||
general = {
|
||||
# Make there be no gaps in between windows or edges
|
||||
border_size = 5;
|
||||
gaps_in = 0;
|
||||
gaps_out = 0;
|
||||
|
||||
resize_on_border = true;
|
||||
};
|
||||
|
||||
windowrulev2 = [
|
||||
"float, class:firefox, title:Picture-in-Picture"
|
||||
"float, class:(clipse)"
|
||||
"move cursor 0 0, class:(clipse)"
|
||||
"size 622 652, class:(clipse)"
|
||||
"noanim, class:(clipse)"
|
||||
];
|
||||
|
||||
animation = [
|
||||
"workspaces, 0, , "
|
||||
];
|
||||
|
||||
# Keybinds
|
||||
bind = [
|
||||
"$mainMod, return, exec, $multiplexer"
|
||||
"$mainMod, W, killactive"
|
||||
"$mainMod, O, exec, $browser"
|
||||
"$mainMod, Escape, exec, hyprlock"
|
||||
"$mainMod, Space, exec, $launcher"
|
||||
|
||||
# Launch utilities
|
||||
"$mainMod_SHIFT, A, exec, hyprpicker -a"
|
||||
"$mainMod, V, exec, $clipboard"
|
||||
|
||||
# move between windows
|
||||
"$mainMod, H, cyclenext, visible"
|
||||
"$mainMod, L, cyclenext, visible prev"
|
||||
|
||||
# HJKL to move a window
|
||||
"$mainMod_ALT, H, movewindow, l"
|
||||
"$mainMod_ALT, J, movewindow, d"
|
||||
"$mainMod_ALT, K, movewindow, u"
|
||||
"$mainMod_ALT, L, movewindow, r"
|
||||
|
||||
# HJKL to resize a window
|
||||
"ALT_SHIFT, H, resizeactive, -10% 0"
|
||||
"ALT_SHIFT, J, resizeactive, 0 -10%"
|
||||
"ALT_SHIFT, K, resizeactive, 0 10%"
|
||||
"ALT_SHIFT, L, resizeactive, 10% 0"
|
||||
|
||||
# H and L to move between workspaces on the current monitor including creation
|
||||
"$mainMod_CTRL, H, workspace, r-1"
|
||||
"$mainMod_CTRL, L, workspace, r+1"
|
||||
];
|
||||
|
||||
# Repeat when held
|
||||
bindle = [
|
||||
# Keyboard Media Keys
|
||||
", XF86AudioRaiseVolume, exec, wpctl set-volume -l 1.5 @DEFAULT_AUDIO_SINK@ 5%+"
|
||||
", XF86AudioLowerVolume, exec, wpctl set-volume -l 1.5 @DEFAULT_AUDIO_SINK@ 5%-"
|
||||
];
|
||||
|
||||
bindm = [
|
||||
"ALT, mouse:272, movewindow"
|
||||
];
|
||||
|
||||
input = {
|
||||
numlock_by_default = true;
|
||||
follow_mouse = 2; # Click on a window to change focus
|
||||
};
|
||||
|
||||
debug = {
|
||||
damage_tracking = 0;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
63
configs/graphical/hyprlock.nix
Normal file
63
configs/graphical/hyprlock.nix
Normal file
|
@ -0,0 +1,63 @@
|
|||
{
|
||||
inputs,
|
||||
hostname,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
cfg =
|
||||
if hostname == "nemesis" then
|
||||
{
|
||||
mainMonitor = "HDMI-A-1";
|
||||
}
|
||||
else
|
||||
{
|
||||
mainMonitor = "";
|
||||
};
|
||||
in
|
||||
{
|
||||
security.pam.services.hyprlock = { };
|
||||
home-manager.users.rafiq = {
|
||||
programs.hyprlock = {
|
||||
enable = true;
|
||||
package = inputs.hyprlock.packages.${pkgs.stdenv.hostPlatform.system}.hyprlock;
|
||||
|
||||
settings = {
|
||||
general = {
|
||||
hide_cursor = true;
|
||||
ignore_empty_input = true;
|
||||
};
|
||||
|
||||
background = {
|
||||
blur_passes = 5;
|
||||
blur_size = 5;
|
||||
};
|
||||
|
||||
label = {
|
||||
monitor = cfg.mainMonitor;
|
||||
text = ''hi, $USER.'';
|
||||
font_size = 32;
|
||||
halign = "center";
|
||||
valign = "center";
|
||||
position = "0, 0";
|
||||
zindex = 1;
|
||||
shadow_passes = 5;
|
||||
shadow_size = 5;
|
||||
};
|
||||
|
||||
input-field = {
|
||||
monitor = cfg.mainMonitor;
|
||||
fade_on_empty = true;
|
||||
size = "200, 45";
|
||||
halign = "center";
|
||||
valign = "center";
|
||||
position = "0, -5%";
|
||||
placeholder_text = "";
|
||||
zindex = 1;
|
||||
shadow_passes = 5;
|
||||
shadow_size = 5;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
25
configs/graphical/hyprshade.nix
Normal file
25
configs/graphical/hyprshade.nix
Normal file
|
@ -0,0 +1,25 @@
|
|||
{ inputs, pkgs, ... }:
|
||||
{
|
||||
home-manager.users.rafiq = {
|
||||
home.packages = [ pkgs.hyprshade ];
|
||||
xdg.configFile."hypr/hyprshade.toml" = {
|
||||
enable = true;
|
||||
text = # toml
|
||||
''
|
||||
[[shades]]
|
||||
name = "vibrance"
|
||||
default = true # will be activated when no other shader is scheduled
|
||||
|
||||
[[shades]]
|
||||
name = "blue-light-filter"
|
||||
start_time = 22:00:00
|
||||
end_time = 08:00:00 # optional if more than one shader has start_time
|
||||
'';
|
||||
};
|
||||
xdg.configFile."hypr/shaders" = {
|
||||
enable = true;
|
||||
recursive = true;
|
||||
source = "${inputs.hyprshaders}/shaders";
|
||||
};
|
||||
};
|
||||
}
|
16
configs/graphical/kitty.nix
Normal file
16
configs/graphical/kitty.nix
Normal file
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
home-manager.users.rafiq = {
|
||||
home.sessionVariables.TERMINAL = "kitty";
|
||||
programs.kitty = {
|
||||
enable = true;
|
||||
keybindings = {
|
||||
"ctrl+equal" = "change_font_size current +2.0";
|
||||
"ctrl+minus" = "change_font_size current -2.0";
|
||||
};
|
||||
settings = {
|
||||
window_padding_width = 10;
|
||||
confirm_os_window_close = 0;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
23
configs/graphical/spicetify.nix
Normal file
23
configs/graphical/spicetify.nix
Normal file
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.stdenv.system};
|
||||
in
|
||||
{
|
||||
home-manager.users.rafiq = {
|
||||
imports = [
|
||||
inputs.spicetify-nix.homeManagerModules.spicetify
|
||||
];
|
||||
programs.spicetify = {
|
||||
enable = true;
|
||||
spotifyLaunchFlags = "--enable-features=UseOzonePlatform --ozone-platform=wayland";
|
||||
windowManagerPatch = true;
|
||||
enabledCustomApps = with spicePkgs.apps; [
|
||||
marketplace
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue