mirror of
https://github.com/jbowdre/dotfiles.git
synced 2024-11-24 18:12:18 +00:00
Compare commits
11 commits
8c7d2af6cd
...
64c5de2f84
Author | SHA1 | Date | |
---|---|---|---|
64c5de2f84 | |||
3e0b5a1872 | |||
9a37482320 | |||
0dfa785ec7 | |||
f54e3593a0 | |||
6d4bfdb7b3 | |||
7481c9f9c7 | |||
0f36251282 | |||
806291470f | |||
3147aa7bf1 | |||
ced05c46c8 |
16 changed files with 302 additions and 76 deletions
24
flake.lock
24
flake.lock
|
@ -9,11 +9,11 @@
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"dir": "pkgs/firefox-addons",
|
"dir": "pkgs/firefox-addons",
|
||||||
"lastModified": 1695441765,
|
"lastModified": 1696061413,
|
||||||
"narHash": "sha256-s6sNoj2bKX9e7eE870o8Osr0lr3jNWUYkgdmIYQPCs8=",
|
"narHash": "sha256-sqwTUo0CG9jmiCrdTNbZw0cbYRQrkgidHIqJ2M9Q8nM=",
|
||||||
"owner": "rycee",
|
"owner": "rycee",
|
||||||
"repo": "nur-expressions",
|
"repo": "nur-expressions",
|
||||||
"rev": "e1c9234dd58dfd8bfa7662df27d6124cad190f2a",
|
"rev": "01661d8650f000a5fc8b0c2c60dce3d2bf5d4b99",
|
||||||
"type": "gitlab"
|
"type": "gitlab"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -40,11 +40,11 @@
|
||||||
},
|
},
|
||||||
"hardware": {
|
"hardware": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1695109627,
|
"lastModified": 1695887975,
|
||||||
"narHash": "sha256-4rpyoVzmunIG6xWA/EonnSSqC69bDBzciFi6SjBze/0=",
|
"narHash": "sha256-u3+5FR12dI305jCMb0fJNQx2qwoQ54lv1tPoEWp0hmg=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixos-hardware",
|
"repo": "nixos-hardware",
|
||||||
"rev": "cb4dc98f776ddb6af165e6f06b2902efe31ca67a",
|
"rev": "adcfd6aa860d1d129055039696bc457af7d50d0e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -139,11 +139,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs-unstable": {
|
"nixpkgs-unstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1695145219,
|
"lastModified": 1695830400,
|
||||||
"narHash": "sha256-Eoe9IHbvmo5wEDeJXKFOpKUwxYJIOxKUesounVccNYk=",
|
"narHash": "sha256-gToZXQVr0G/1WriO83olnqrLSHF2Jb8BPcmCt497ro0=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "5ba549eafcf3e33405e5f66decd1a72356632b96",
|
"rev": "8a86b98f0ba1c405358f1b71ff8b5e1d317f5db2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -155,11 +155,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1695346609,
|
"lastModified": 1695825837,
|
||||||
"narHash": "sha256-jur+AjgRvablLA2oBvC4FD89zCXttVQDwi6OXk5x/14=",
|
"narHash": "sha256-4Ne11kNRnQsmSJCRSSNkFRSnHC4Y5gPDBIQGjjPfJiU=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "e9b4b56e5a20ac322c0c01ccab7ec697ab076ea0",
|
"rev": "5cfafa12d57374f48bcc36fda3274ada276cf69e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
|
@ -77,11 +77,7 @@
|
||||||
extraSpecialArgs = { inherit inputs outputs; };
|
extraSpecialArgs = { inherit inputs outputs; };
|
||||||
};
|
};
|
||||||
"john@pixnix" = lib.homeManagerConfiguration {
|
"john@pixnix" = lib.homeManagerConfiguration {
|
||||||
modules = [
|
modules = [ ./home/pixnix.nix ];
|
||||||
./home/pixnix.nix
|
|
||||||
hyprland.homeManagerModules.default
|
|
||||||
{wayland.windowManager.hyprland.enable = true;}
|
|
||||||
];
|
|
||||||
pkgs = pkgsFor.x86_64-linux;
|
pkgs = pkgsFor.x86_64-linux;
|
||||||
extraSpecialArgs = { inherit inputs outputs; };
|
extraSpecialArgs = { inherit inputs outputs; };
|
||||||
};
|
};
|
||||||
|
|
|
@ -2,6 +2,8 @@
|
||||||
# Common GUI apps
|
# Common GUI apps
|
||||||
imports = [
|
imports = [
|
||||||
./firefox.nix
|
./firefox.nix
|
||||||
|
./gtk.nix
|
||||||
|
./qt.nix
|
||||||
./vscode.nix
|
./vscode.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
9
home/features/desktop/gtk.nix
Normal file
9
home/features/desktop/gtk.nix
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
{ config, pkgs, inputs, ... }: {
|
||||||
|
gtk = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
services.xsettingsd = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
}
|
59
home/features/desktop/hyprland/binds.nix
Normal file
59
home/features/desktop/hyprland/binds.nix
Normal file
|
@ -0,0 +1,59 @@
|
||||||
|
{
|
||||||
|
wayland.windowManager.hyprland.extraConfig = ''
|
||||||
|
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||||
|
$mainMod = SUPER
|
||||||
|
|
||||||
|
# Alt-Tab action
|
||||||
|
bind = ALT, Tab, cyclenext,
|
||||||
|
bind = ALT, Tab, bringactivetotop,
|
||||||
|
|
||||||
|
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
|
||||||
|
bind = $mainMod, Q, exec, kitty
|
||||||
|
bind = $mainMod, C, killactive,
|
||||||
|
bind = $mainMod, M, exit,
|
||||||
|
bind = $mainMod, E, exec, dolphin
|
||||||
|
bind = $mainMod, F, exec, firefox
|
||||||
|
bind = $mainMod, V, togglefloating,
|
||||||
|
bind = $mainMod, R, exec, wofi --show drun
|
||||||
|
bind = $mainMod, P, pseudo, # dwindle
|
||||||
|
bind = $mainMod, J, togglesplit, # dwindle
|
||||||
|
|
||||||
|
# Move focus with mainMod + arrow keys
|
||||||
|
bind = $mainMod, left, movefocus, l
|
||||||
|
bind = $mainMod, right, movefocus, r
|
||||||
|
bind = $mainMod, up, movefocus, u
|
||||||
|
bind = $mainMod, down, movefocus, d
|
||||||
|
|
||||||
|
# Switch workspaces with mainMod + [0-9]
|
||||||
|
bind = $mainMod, 1, workspace, 1
|
||||||
|
bind = $mainMod, 2, workspace, 2
|
||||||
|
bind = $mainMod, 3, workspace, 3
|
||||||
|
bind = $mainMod, 4, workspace, 4
|
||||||
|
bind = $mainMod, 5, workspace, 5
|
||||||
|
bind = $mainMod, 6, workspace, 6
|
||||||
|
bind = $mainMod, 7, workspace, 7
|
||||||
|
bind = $mainMod, 8, workspace, 8
|
||||||
|
bind = $mainMod, 9, workspace, 9
|
||||||
|
bind = $mainMod, 0, workspace, 10
|
||||||
|
|
||||||
|
# Move active window to a workspace with mainMod + SHIFT + [0-9]
|
||||||
|
bind = $mainMod SHIFT, 1, movetoworkspace, 1
|
||||||
|
bind = $mainMod SHIFT, 2, movetoworkspace, 2
|
||||||
|
bind = $mainMod SHIFT, 3, movetoworkspace, 3
|
||||||
|
bind = $mainMod SHIFT, 4, movetoworkspace, 4
|
||||||
|
bind = $mainMod SHIFT, 5, movetoworkspace, 5
|
||||||
|
bind = $mainMod SHIFT, 6, movetoworkspace, 6
|
||||||
|
bind = $mainMod SHIFT, 7, movetoworkspace, 7
|
||||||
|
bind = $mainMod SHIFT, 8, movetoworkspace, 8
|
||||||
|
bind = $mainMod SHIFT, 9, movetoworkspace, 9
|
||||||
|
bind = $mainMod SHIFT, 0, movetoworkspace, 10
|
||||||
|
|
||||||
|
# Scroll through existing workspaces with mainMod + scroll
|
||||||
|
bind = $mainMod, mouse_down, workspace, e+1
|
||||||
|
bind = $mainMod, mouse_up, workspace, e-1
|
||||||
|
|
||||||
|
# Move/resize windows with mainMod + LMB/RMB and dragging
|
||||||
|
bindm = $mainMod, mouse:272, movewindow
|
||||||
|
bindm = $mainMod, mouse:273, resizewindow
|
||||||
|
'';
|
||||||
|
}
|
|
@ -1,7 +1,19 @@
|
||||||
{ config, inputs, pkgs, ... }: {
|
{ config, inputs, pkgs, ... }: {
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./binds.nix
|
||||||
|
./tty-init.nix
|
||||||
|
../wayland-wm
|
||||||
|
];
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
hyprpicker
|
||||||
|
];
|
||||||
|
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
enable = true;
|
enable = true;
|
||||||
systemdIntegration = true;
|
systemdIntegration = true;
|
||||||
|
xwayland.enable = true;
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
# This is an example Hyprland config file.
|
# This is an example Hyprland config file.
|
||||||
#
|
#
|
||||||
|
@ -13,7 +25,11 @@
|
||||||
#
|
#
|
||||||
|
|
||||||
# See https://wiki.hyprland.org/Configuring/Monitors/
|
# See https://wiki.hyprland.org/Configuring/Monitors/
|
||||||
monitor=,preferred,auto,auto
|
monitor=eDP-1,2400x1600,auto,1.5
|
||||||
|
|
||||||
|
xwayland {
|
||||||
|
force_zero_scaling = true
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||||
|
@ -38,7 +54,8 @@
|
||||||
follow_mouse = 1
|
follow_mouse = 1
|
||||||
|
|
||||||
touchpad {
|
touchpad {
|
||||||
natural_scroll = false
|
natural_scroll = true
|
||||||
|
clickfinger_behavior = true
|
||||||
}
|
}
|
||||||
|
|
||||||
sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
|
sensitivity = 0 # -1.0 - 1.0, 0 means no modification.
|
||||||
|
@ -47,8 +64,8 @@
|
||||||
general {
|
general {
|
||||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||||
|
|
||||||
gaps_in = 5
|
gaps_in = 2
|
||||||
gaps_out = 20
|
gaps_out = 6
|
||||||
border_size = 2
|
border_size = 2
|
||||||
col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
|
col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
|
||||||
col.inactive_border = rgba(595959aa)
|
col.inactive_border = rgba(595959aa)
|
||||||
|
@ -62,7 +79,7 @@
|
||||||
decoration {
|
decoration {
|
||||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||||
|
|
||||||
rounding = 10
|
rounding = 6
|
||||||
|
|
||||||
blur {
|
blur {
|
||||||
enabled = true
|
enabled = true
|
||||||
|
@ -104,7 +121,8 @@
|
||||||
|
|
||||||
gestures {
|
gestures {
|
||||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||||
workspace_swipe = false
|
workspace_swipe = true
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Example per-device config
|
# Example per-device config
|
||||||
|
@ -119,58 +137,11 @@
|
||||||
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
|
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
|
||||||
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
|
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
|
||||||
|
|
||||||
|
|
||||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
|
||||||
$mainMod = SUPER
|
|
||||||
|
|
||||||
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
|
|
||||||
bind = $mainMod, Q, exec, kitty
|
|
||||||
bind = $mainMod, C, killactive,
|
|
||||||
bind = $mainMod, M, exit,
|
|
||||||
bind = $mainMod, E, exec, dolphin
|
|
||||||
bind = $mainMod, V, togglefloating,
|
|
||||||
bind = $mainMod, R, exec, wofi --show drun
|
|
||||||
bind = $mainMod, P, pseudo, # dwindle
|
|
||||||
bind = $mainMod, J, togglesplit, # dwindle
|
|
||||||
|
|
||||||
# Move focus with mainMod + arrow keys
|
|
||||||
bind = $mainMod, left, movefocus, l
|
|
||||||
bind = $mainMod, right, movefocus, r
|
|
||||||
bind = $mainMod, up, movefocus, u
|
|
||||||
bind = $mainMod, down, movefocus, d
|
|
||||||
|
|
||||||
# Switch workspaces with mainMod + [0-9]
|
|
||||||
bind = $mainMod, 1, workspace, 1
|
|
||||||
bind = $mainMod, 2, workspace, 2
|
|
||||||
bind = $mainMod, 3, workspace, 3
|
|
||||||
bind = $mainMod, 4, workspace, 4
|
|
||||||
bind = $mainMod, 5, workspace, 5
|
|
||||||
bind = $mainMod, 6, workspace, 6
|
|
||||||
bind = $mainMod, 7, workspace, 7
|
|
||||||
bind = $mainMod, 8, workspace, 8
|
|
||||||
bind = $mainMod, 9, workspace, 9
|
|
||||||
bind = $mainMod, 0, workspace, 10
|
|
||||||
|
|
||||||
# Move active window to a workspace with mainMod + SHIFT + [0-9]
|
|
||||||
bind = $mainMod SHIFT, 1, movetoworkspace, 1
|
|
||||||
bind = $mainMod SHIFT, 2, movetoworkspace, 2
|
|
||||||
bind = $mainMod SHIFT, 3, movetoworkspace, 3
|
|
||||||
bind = $mainMod SHIFT, 4, movetoworkspace, 4
|
|
||||||
bind = $mainMod SHIFT, 5, movetoworkspace, 5
|
|
||||||
bind = $mainMod SHIFT, 6, movetoworkspace, 6
|
|
||||||
bind = $mainMod SHIFT, 7, movetoworkspace, 7
|
|
||||||
bind = $mainMod SHIFT, 8, movetoworkspace, 8
|
|
||||||
bind = $mainMod SHIFT, 9, movetoworkspace, 9
|
|
||||||
bind = $mainMod SHIFT, 0, movetoworkspace, 10
|
|
||||||
|
|
||||||
# Scroll through existing workspaces with mainMod + scroll
|
|
||||||
bind = $mainMod, mouse_down, workspace, e+1
|
|
||||||
bind = $mainMod, mouse_up, workspace, e-1
|
|
||||||
|
|
||||||
# Move/resize windows with mainMod + LMB/RMB and dragging
|
|
||||||
bindm = $mainMod, mouse:272, movewindow
|
|
||||||
bindm = $mainMod, mouse:273, resizewindow
|
|
||||||
|
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# VSCode scaling fix
|
||||||
|
programs.vscode.userSettings = {
|
||||||
|
"window.zoomLevel" = 2;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
9
home/features/desktop/hyprland/tty-init.nix
Normal file
9
home/features/desktop/hyprland/tty-init.nix
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
{
|
||||||
|
programs = {
|
||||||
|
fish.loginShellInit = ''
|
||||||
|
if test (tty) = "/dev/tty1"
|
||||||
|
exec Hyprland &> /dev/null
|
||||||
|
end
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
10
home/features/desktop/qt.nix
Normal file
10
home/features/desktop/qt.nix
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
{ pkgs, cofig, ... }: {
|
||||||
|
qt = {
|
||||||
|
enable = true;
|
||||||
|
platformTheme = "gtk";
|
||||||
|
style = {
|
||||||
|
name = "gtk2";
|
||||||
|
package = pkgs.qt6Packages.qt6gtk2;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
32
home/features/desktop/wayland-wm/default.nix
Normal file
32
home/features/desktop/wayland-wm/default.nix
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
{ pkgs, ... }: {
|
||||||
|
imports = [
|
||||||
|
./kitty.nix
|
||||||
|
./mako.nix
|
||||||
|
./waybar.nix
|
||||||
|
./wofi.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
xdg.mimeApps.enable = true;
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
grim
|
||||||
|
gtk3
|
||||||
|
imv
|
||||||
|
mimeo
|
||||||
|
# primary-xwayland
|
||||||
|
pulseaudio
|
||||||
|
slurp
|
||||||
|
waypipe
|
||||||
|
wf-recorder
|
||||||
|
wl-clipboard
|
||||||
|
wl-mirror
|
||||||
|
# wl-mirror-pick
|
||||||
|
# xdg-utils-spawn-terminal
|
||||||
|
ydotool
|
||||||
|
];
|
||||||
|
|
||||||
|
home.sessionVariables = {
|
||||||
|
MOZ_ENABLE_WAYLAND = 1;
|
||||||
|
QT_QPA_PLATFORM = "wayland";
|
||||||
|
LIBSEAT_BACKEND = "logind";
|
||||||
|
};
|
||||||
|
}
|
21
home/features/desktop/wayland-wm/kitty.nix
Normal file
21
home/features/desktop/wayland-wm/kitty.nix
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
{ config, pkgs, ... }:
|
||||||
|
let
|
||||||
|
kitty-xterm = pkgs.writeShellScriptBin "xterm" ''
|
||||||
|
${config.programs.kitty.package}/bin/kitty -1 "$@"
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
{
|
||||||
|
home = {
|
||||||
|
packages = [ kitty-xterm ];
|
||||||
|
sessionVariables = {
|
||||||
|
TERMINAL = "kitty -1";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.kitty = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
scrollback_lines = 4000;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
5
home/features/desktop/wayland-wm/mako.nix
Normal file
5
home/features/desktop/wayland-wm/mako.nix
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
{
|
||||||
|
services.mako = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
}
|
49
home/features/desktop/wayland-wm/waybar.nix
Normal file
49
home/features/desktop/wayland-wm/waybar.nix
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
{ ouputs, cofig, lib, pkgs, ... }:
|
||||||
|
let
|
||||||
|
cat = "${pkgs.coreutils}/bin/cat";
|
||||||
|
cut = "${pkgs.coreutils}/bin/cut";
|
||||||
|
find = "${pkgs.findutils}/bin/find";
|
||||||
|
grep = "${pkgs.gnugrep}/bin/grep";
|
||||||
|
journalctl = "${pkgs.systemd}/bin/journalctl";
|
||||||
|
jq = "${pkgs.jq}/bin/jq";
|
||||||
|
pgrep = "${pkgs.procps}/bin/pgrep";
|
||||||
|
ping = "${pkgs.iputils}/bin/ping";
|
||||||
|
playerctl = "${pkgs.playerctl}/bin/playerctl";
|
||||||
|
playerctld = "${pkgs.playerctl}/bin/playerctld";
|
||||||
|
systemctl = "${pkgs.systemd}/bin/systemctl";
|
||||||
|
tail = "${pkgs.coreutils}/bin/tail";
|
||||||
|
timeout = "${pkgs.coreutils}/bin/timeout";
|
||||||
|
wc = "${pkgs.coreutils}/bin/wc";
|
||||||
|
wofi = "${pkgs.wofi}/bin/wofi";
|
||||||
|
xargs = "${pkgs.findutils}/bin/xargs";
|
||||||
|
|
||||||
|
jsonOutput = name: { pre ? "", text ? "", tooltip ? "", alt? "", class ? "", percentage ? "" }: "${pkgs.writeShellScriptBin "waybar-${name}" ''
|
||||||
|
set -euo pipefail
|
||||||
|
${pre}
|
||||||
|
${jq} -cn \
|
||||||
|
--arg text "${text}" \
|
||||||
|
--arg tooltip "${tooltip}" \
|
||||||
|
--arg alt "${alt}" \
|
||||||
|
--arg class "${class}" \
|
||||||
|
--arg percentage "${percentage}" \
|
||||||
|
'{text:$text,tooltip:$tooltip,alt:$alt,class:$class,percentage:$percentage}'
|
||||||
|
''}/bin/waybar-${name}";
|
||||||
|
in
|
||||||
|
{
|
||||||
|
programs.waybar = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.waybar.overrideAttrs (oa: {
|
||||||
|
mesonFlags = (oa.mesonFlags or [ ]) ++ [ "-Dexperimental=true" ];
|
||||||
|
});
|
||||||
|
systemd.enable = true;
|
||||||
|
settings = {
|
||||||
|
primary = {
|
||||||
|
mode = "dock";
|
||||||
|
layer = "top";
|
||||||
|
position = "top";
|
||||||
|
height = 24;
|
||||||
|
margin = "6";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
20
home/features/desktop/wayland-wm/wofi-run-shell.patch
Normal file
20
home/features/desktop/wayland-wm/wofi-run-shell.patch
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
--- a/src/wofi.c Mon Feb 22 23:53:57 2021 -0800
|
||||||
|
+++ b/src/wofi.c Wed Aug 11 13:49:13 2021 -0300
|
||||||
|
@@ -881,12 +881,15 @@
|
||||||
|
}
|
||||||
|
|
||||||
|
void wofi_term_run(const char* cmd) {
|
||||||
|
+ char *shell = getenv("SHELL");
|
||||||
|
+ if (!shell) shell = "sh";
|
||||||
|
+
|
||||||
|
if(terminal != NULL) {
|
||||||
|
- execlp(terminal, terminal, "-e", cmd, NULL);
|
||||||
|
+ execlp(terminal, terminal, "-e", shell, "-c", cmd, NULL);
|
||||||
|
}
|
||||||
|
size_t term_count = sizeof(terminals) / sizeof(char*);
|
||||||
|
for(size_t count = 0; count < term_count; ++count) {
|
||||||
|
- execlp(terminals[count], terminals[count], "-e", cmd, NULL);
|
||||||
|
+ execlp(terminals[count], terminals[count], "-e", shell, "-c", cmd, NULL);
|
||||||
|
}
|
||||||
|
fprintf(stderr, "No terminal emulator found please set term in config or use --term\n");
|
||||||
|
exit(1);
|
19
home/features/desktop/wayland-wm/wofi.nix
Normal file
19
home/features/desktop/wayland-wm/wofi.nix
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
{ config, lib, pkgs, ... }: {
|
||||||
|
programs.wofi = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.wofi.overrideAttrs (oa: {
|
||||||
|
patches = (oa.patches or [ ]) ++ [
|
||||||
|
./wofi-run-shell.patch # Fix for https://todo.sr.ht/~scoopta/wofi/174
|
||||||
|
];
|
||||||
|
});
|
||||||
|
settings = {
|
||||||
|
image_size = 48;
|
||||||
|
columns = 3;
|
||||||
|
allow_images = true;
|
||||||
|
insensitive = true;
|
||||||
|
run-always_parse_args = true;
|
||||||
|
run-cache_file = "/dev/null";
|
||||||
|
run-exec_search = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
18
hosts/common/optional/greetd.nix
Normal file
18
hosts/common/optional/greetd.nix
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
{ pkgs, ... }: {
|
||||||
|
services.greetd = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
default_session.command = ''
|
||||||
|
${pkgs.greetd.tuigreet}/bin/tuigreet \
|
||||||
|
--time \
|
||||||
|
--asterisks \
|
||||||
|
--user-menu \
|
||||||
|
--cmd Hyprland
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.etc."greetd/environments".text = ''
|
||||||
|
Hyprland
|
||||||
|
'';
|
||||||
|
}
|
|
@ -9,6 +9,7 @@
|
||||||
../common/users/john
|
../common/users/john
|
||||||
|
|
||||||
../common/optional/docker.nix
|
../common/optional/docker.nix
|
||||||
|
../common/optional/greetd.nix
|
||||||
../common/optional/hyprland.nix
|
../common/optional/hyprland.nix
|
||||||
../common/optional/libvirtd.nix
|
../common/optional/libvirtd.nix
|
||||||
../common/optional/pipewire.nix
|
../common/optional/pipewire.nix
|
||||||
|
@ -21,6 +22,11 @@
|
||||||
networkmanager.enable = true;
|
networkmanager.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
xdg.portal = {
|
||||||
|
enable = true;
|
||||||
|
wlr.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
system.stateVersion = "23.05";
|
system.stateVersion = "23.05";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue