mirror of
https://github.com/alyraffauf/nixcfg.git
synced 2024-11-22 07:53:55 -05:00
home: nixified river config and added lavaridge outputs
This commit is contained in:
parent
a521544cda
commit
9f2de2ba5a
|
@ -7,5 +7,4 @@
|
||||||
imports = [./gnome ./hypr ./sway ./river];
|
imports = [./gnome ./hypr ./sway ./river];
|
||||||
|
|
||||||
desktopEnv.hyprland.enable = lib.mkDefault true;
|
desktopEnv.hyprland.enable = lib.mkDefault true;
|
||||||
desktopEnv.river.enable = lib.mkDefault true;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf config.desktopEnv.river.enable {
|
config = lib.mkIf config.desktopEnv.river.enable {
|
||||||
# Basic apps needed to run a hyprland desktop.
|
# Basic apps needed to run a riverwm desktop.
|
||||||
guiApps.waybar.enable = lib.mkDefault true;
|
guiApps.waybar.enable = lib.mkDefault true;
|
||||||
guiApps.mako.enable = lib.mkDefault true;
|
guiApps.mako.enable = lib.mkDefault true;
|
||||||
guiApps.fuzzel.enable = lib.mkDefault true;
|
guiApps.fuzzel.enable = lib.mkDefault true;
|
||||||
|
@ -49,7 +49,7 @@
|
||||||
outputs = [
|
outputs = [
|
||||||
{
|
{
|
||||||
status = "enable";
|
status = "enable";
|
||||||
criteria = "BOE 0x095F";
|
criteria = "BOE 0x095F Unknown";
|
||||||
scale = 1.5;
|
scale = 1.5;
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
@ -63,8 +63,8 @@
|
||||||
|
|
||||||
xdg.portal = {
|
xdg.portal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
configPackages = [pkgs.xdg-desktop-portal-hyprland];
|
configPackages = [pkgs.xdg-desktop-portal-wlr];
|
||||||
extraPortals = [pkgs.xdg-desktop-portal-hyprland];
|
extraPortals = [pkgs.xdg-desktop-portal-wlr];
|
||||||
};
|
};
|
||||||
|
|
||||||
gtk.gtk3.extraCss = ''
|
gtk.gtk3.extraCss = ''
|
||||||
|
@ -157,172 +157,175 @@
|
||||||
qt_platform_theme = "gtk2";
|
qt_platform_theme = "gtk2";
|
||||||
gdk_scale = "1.5";
|
gdk_scale = "1.5";
|
||||||
in ''
|
in ''
|
||||||
|
pkill -f kanshi
|
||||||
|
pkill -f mako
|
||||||
|
pkill -f nm-applet
|
||||||
|
pkill -f swayosd-server
|
||||||
|
pkill -f waybar
|
||||||
|
|
||||||
touchpad=`riverctl list-inputs|grep -i touchpad`
|
touchpad=`riverctl list-inputs|grep -i touchpad`
|
||||||
for t in ''${touchpad[@]}; do
|
for t in ''${touchpad[@]}; do
|
||||||
riverctl input $t natural-scroll enabled
|
riverctl input $t natural-scroll enabled
|
||||||
riverctl input $t click-method clickfinger
|
riverctl input $t click-method clickfinger
|
||||||
riverctl input $t tap enabled
|
riverctl input $t tap enabled
|
||||||
riverctl input $t disable-while-typing enabled
|
riverctl input $t disable-while-typing enabled
|
||||||
done
|
done
|
||||||
|
|
||||||
riverctl focus-follows-cursor always
|
riverctl focus-follows-cursor always
|
||||||
|
|
||||||
riverctl map normal ${modifier} T spawn ${terminal}
|
riverctl map normal ${modifier} T spawn ${terminal}
|
||||||
riverctl map normal ${modifier} R spawn ${launcher}
|
riverctl map normal ${modifier} R spawn ${launcher}
|
||||||
riverctl map normal ${modifier} B spawn ${browser}
|
riverctl map normal ${modifier} B spawn ${browser}
|
||||||
riverctl map normal ${modifier} E spawn ${editor}
|
riverctl map normal ${modifier} E spawn ${editor}
|
||||||
riverctl map normal ${modifier} F spawn ${fileManager}
|
riverctl map normal ${modifier} F spawn ${fileManager}
|
||||||
|
|
||||||
riverctl map normal ${modifier} M spawn ${logout}
|
riverctl map normal ${modifier} M spawn ${logout}
|
||||||
|
|
||||||
# ${modifier}+C to close the focused view
|
# ${modifier}+C to close the focused view
|
||||||
riverctl map normal ${modifier} C close
|
riverctl map normal ${modifier} C close
|
||||||
|
|
||||||
# ${modifier}+Shift+E to exit river
|
# ${modifier}+Shift+E to exit river
|
||||||
riverctl map normal ${modifier}+Shift E exit
|
riverctl map normal ${modifier}+Shift E exit
|
||||||
|
|
||||||
# ${modifier}+J and ${modifier}+K to focus the next/previous view in the layout stack
|
# ${modifier}+J and ${modifier}+K to focus the next/previous view in the layout stack
|
||||||
riverctl map normal ${modifier} J focus-view next
|
riverctl map normal ${modifier} J focus-view next
|
||||||
riverctl map normal ${modifier} K focus-view previous
|
riverctl map normal ${modifier} K focus-view previous
|
||||||
|
|
||||||
# ${modifier}+Shift+J and ${modifier}+Shift+K to swap the focused view with the next/previous
|
# ${modifier}+Shift+J and ${modifier}+Shift+K to swap the focused view with the next/previous
|
||||||
# view in the layout stack
|
# view in the layout stack
|
||||||
riverctl map normal ${modifier}+Shift J swap next
|
riverctl map normal ${modifier}+Shift J swap next
|
||||||
riverctl map normal ${modifier}+Shift K swap previous
|
riverctl map normal ${modifier}+Shift K swap previous
|
||||||
|
|
||||||
# ${modifier}+Period and ${modifier}+Comma to focus the next/previous output
|
# ${modifier}+Period and ${modifier}+Comma to focus the next/previous output
|
||||||
riverctl map normal ${modifier} Period focus-output next
|
riverctl map normal ${modifier} Period focus-output next
|
||||||
riverctl map normal ${modifier} Comma focus-output previous
|
riverctl map normal ${modifier} Comma focus-output previous
|
||||||
|
|
||||||
# ${modifier}+Shift+{Period,Comma} to send the focused view to the next/previous output
|
# ${modifier}+Shift+{Period,Comma} to send the focused view to the next/previous output
|
||||||
riverctl map normal ${modifier}+Shift Period send-to-output next
|
riverctl map normal ${modifier}+Shift Period send-to-output next
|
||||||
riverctl map normal ${modifier}+Shift Comma send-to-output previous
|
riverctl map normal ${modifier}+Shift Comma send-to-output previous
|
||||||
|
|
||||||
# ${modifier}+Return to bump the focused view to the top of the layout stack
|
# ${modifier}+Return to bump the focused view to the top of the layout stack
|
||||||
riverctl map normal ${modifier} Return zoom
|
riverctl map normal ${modifier} Return zoom
|
||||||
|
|
||||||
# ${modifier}+H and ${modifier}+L to decrease/increase the main ratio of rivertile(1)
|
# ${modifier}+H and ${modifier}+L to decrease/increase the main ratio of rivertile(1)
|
||||||
riverctl map normal ${modifier} H send-layout-cmd rivertile "main-ratio -0.05"
|
riverctl map normal ${modifier} H send-layout-cmd rivertile "main-ratio -0.05"
|
||||||
riverctl map normal ${modifier} L send-layout-cmd rivertile "main-ratio +0.05"
|
riverctl map normal ${modifier} L send-layout-cmd rivertile "main-ratio +0.05"
|
||||||
|
|
||||||
# ${modifier}+Shift+H and ${modifier}+Shift+L to increment/decrement the main count of rivertile(1)
|
# ${modifier}+Shift+H and ${modifier}+Shift+L to increment/decrement the main count of rivertile(1)
|
||||||
riverctl map normal ${modifier}+Shift H send-layout-cmd rivertile "main-count +1"
|
riverctl map normal ${modifier}+Shift H send-layout-cmd rivertile "main-count +1"
|
||||||
riverctl map normal ${modifier}+Shift L send-layout-cmd rivertile "main-count -1"
|
riverctl map normal ${modifier}+Shift L send-layout-cmd rivertile "main-count -1"
|
||||||
|
|
||||||
# ${modifier}+Alt+{H,J,K,L} to move views
|
# ${modifier}+Alt+{H,J,K,L} to move views
|
||||||
riverctl map normal ${modifier}+Alt H move left 100
|
riverctl map normal ${modifier}+Alt H move left 100
|
||||||
riverctl map normal ${modifier}+Alt J move down 100
|
riverctl map normal ${modifier}+Alt J move down 100
|
||||||
riverctl map normal ${modifier}+Alt K move up 100
|
riverctl map normal ${modifier}+Alt K move up 100
|
||||||
riverctl map normal ${modifier}+Alt L move right 100
|
riverctl map normal ${modifier}+Alt L move right 100
|
||||||
|
|
||||||
# ${modifier}+Alt+Control+{H,J,K,L} to snap views to screen edges
|
# ${modifier}+Alt+Control+{H,J,K,L} to snap views to screen edges
|
||||||
riverctl map normal ${modifier}+Alt+Control H snap left
|
riverctl map normal ${modifier}+Alt+Control H snap left
|
||||||
riverctl map normal ${modifier}+Alt+Control J snap down
|
riverctl map normal ${modifier}+Alt+Control J snap down
|
||||||
riverctl map normal ${modifier}+Alt+Control K snap up
|
riverctl map normal ${modifier}+Alt+Control K snap up
|
||||||
riverctl map normal ${modifier}+Alt+Control L snap right
|
riverctl map normal ${modifier}+Alt+Control L snap right
|
||||||
|
|
||||||
# ${modifier}+Alt+Shift+{H,J,K,L} to resize views
|
# ${modifier}+Alt+Shift+{H,J,K,L} to resize views
|
||||||
riverctl map normal ${modifier}+Alt+Shift H resize horizontal -100
|
riverctl map normal ${modifier}+Alt+Shift H resize horizontal -100
|
||||||
riverctl map normal ${modifier}+Alt+Shift J resize vertical 100
|
riverctl map normal ${modifier}+Alt+Shift J resize vertical 100
|
||||||
riverctl map normal ${modifier}+Alt+Shift K resize vertical -100
|
riverctl map normal ${modifier}+Alt+Shift K resize vertical -100
|
||||||
riverctl map normal ${modifier}+Alt+Shift L resize horizontal 100
|
riverctl map normal ${modifier}+Alt+Shift L resize horizontal 100
|
||||||
|
|
||||||
# ${modifier} + Left Mouse Button to move views
|
# ${modifier} + Left Mouse Button to move views
|
||||||
riverctl map-pointer normal ${modifier} BTN_LEFT move-view
|
riverctl map-pointer normal ${modifier} BTN_LEFT move-view
|
||||||
|
|
||||||
# ${modifier} + Right Mouse Button to resize views
|
# ${modifier} + Right Mouse Button to resize views
|
||||||
riverctl map-pointer normal ${modifier} BTN_RIGHT resize-view
|
riverctl map-pointer normal ${modifier} BTN_RIGHT resize-view
|
||||||
|
|
||||||
# ${modifier} + Middle Mouse Button to toggle float
|
# ${modifier} + Middle Mouse Button to toggle float
|
||||||
riverctl map-pointer normal ${modifier} BTN_MIDDLE toggle-float
|
riverctl map-pointer normal ${modifier} BTN_MIDDLE toggle-float
|
||||||
|
|
||||||
for i in $(seq 1 8)
|
for i in $(seq 1 8)
|
||||||
do
|
do
|
||||||
tags=$((1 << ($i - 1)))
|
tags=$((1 << ($i - 1)))
|
||||||
|
|
||||||
# ${modifier}+[1-9] to focus tag [0-8]
|
# ${modifier}+[1-9] to focus tag [0-8]
|
||||||
riverctl map normal ${modifier} $i set-focused-tags $tags
|
riverctl map normal ${modifier} $i set-focused-tags $tags
|
||||||
|
|
||||||
# ${modifier}+Shift+[1-9] to tag focused view with tag [0-8]
|
# ${modifier}+Shift+[1-9] to tag focused view with tag [0-8]
|
||||||
riverctl map normal ${modifier}+Shift $i set-view-tags $tags
|
riverctl map normal ${modifier}+Shift $i set-view-tags $tags
|
||||||
|
|
||||||
# ${modifier}+Control+[1-9] to toggle focus of tag [0-8]
|
# ${modifier}+Control+[1-9] to toggle focus of tag [0-8]
|
||||||
riverctl map normal ${modifier}+Control $i toggle-focused-tags $tags
|
riverctl map normal ${modifier}+Control $i toggle-focused-tags $tags
|
||||||
|
|
||||||
# ${modifier}+Shift+Control+[1-9] to toggle tag [0-8] of focused view
|
# ${modifier}+Shift+Control+[1-9] to toggle tag [0-8] of focused view
|
||||||
riverctl map normal ${modifier}+Shift+Control $i toggle-view-tags $tags
|
riverctl map normal ${modifier}+Shift+Control $i toggle-view-tags $tags
|
||||||
done
|
done
|
||||||
|
|
||||||
# ${modifier}+0 to focus all tags
|
# ${modifier}+0 to focus all tags
|
||||||
# ${modifier}+Shift+0 to tag focused view with all tags
|
# ${modifier}+Shift+0 to tag focused view with all tags
|
||||||
all_tags=$(((1 << 32) - 1))
|
all_tags=$(((1 << 32) - 1))
|
||||||
riverctl map normal ${modifier} 0 set-focused-tags $all_tags
|
riverctl map normal ${modifier} 0 set-focused-tags $all_tags
|
||||||
riverctl map normal ${modifier}+Shift 0 set-view-tags $all_tags
|
riverctl map normal ${modifier}+Shift 0 set-view-tags $all_tags
|
||||||
|
|
||||||
# ${modifier}+Space to toggle float
|
# ${modifier}+Space to toggle float
|
||||||
riverctl map normal ${modifier} V toggle-float
|
riverctl map normal ${modifier} V toggle-float
|
||||||
|
|
||||||
# ${modifier}+F to toggle fullscreen
|
# ${modifier}+F to toggle fullscreen
|
||||||
riverctl map normal ${modifier} W toggle-fullscreen
|
riverctl map normal ${modifier} W toggle-fullscreen
|
||||||
|
|
||||||
# ${modifier}+{Up,Right,Down,Left} to change layout orientation
|
# ${modifier}+{Up,Right,Down,Left} to change layout orientation
|
||||||
riverctl map normal ${modifier} Up send-layout-cmd rivertile "main-location top"
|
riverctl map normal ${modifier} Up send-layout-cmd rivertile "main-location top"
|
||||||
riverctl map normal ${modifier} Right send-layout-cmd rivertile "main-location right"
|
riverctl map normal ${modifier} Right send-layout-cmd rivertile "main-location right"
|
||||||
riverctl map normal ${modifier} Down send-layout-cmd rivertile "main-location bottom"
|
riverctl map normal ${modifier} Down send-layout-cmd rivertile "main-location bottom"
|
||||||
riverctl map normal ${modifier} Left send-layout-cmd rivertile "main-location left"
|
riverctl map normal ${modifier} Left send-layout-cmd rivertile "main-location left"
|
||||||
|
|
||||||
# Declare a passthrough mode. This mode has only a single mapping to return to
|
# Declare a passthrough mode. This mode has only a single mapping to return to
|
||||||
# normal mode. This makes it useful for testing a nested wayland compositor
|
# normal mode. This makes it useful for testing a nested wayland compositor
|
||||||
riverctl declare-mode passthrough
|
riverctl declare-mode passthrough
|
||||||
|
|
||||||
# ${modifier}+F11 to enter passthrough mode
|
# ${modifier}+F11 to enter passthrough mode
|
||||||
riverctl map normal ${modifier} F11 enter-mode passthrough
|
riverctl map normal ${modifier} F11 enter-mode passthrough
|
||||||
|
|
||||||
# ${modifier}+F11 to return to normal mode
|
# ${modifier}+F11 to return to normal mode
|
||||||
riverctl map passthrough ${modifier} F11 enter-mode normal
|
riverctl map passthrough ${modifier} F11 enter-mode normal
|
||||||
|
|
||||||
# Various media key mapping examples for both normal and locked mode which do
|
# Various media key mapping examples for both normal and locked mode which do
|
||||||
# not have a modifier
|
# not have a modifier
|
||||||
for mode in normal locked
|
for mode in normal locked
|
||||||
do
|
do
|
||||||
# Eject the optical drive (well if you still have one that is)
|
riverctl map $mode None XF86Eject spawn 'eject -T'
|
||||||
riverctl map $mode None XF86Eject spawn 'eject -T'
|
|
||||||
|
|
||||||
# Control pulse audio volume with pamixer (https://github.com/cdemoulins/pamixer)
|
# Control pulse audio volume with pamixer (https://github.com/cdemoulins/pamixer)
|
||||||
riverctl map $mode None XF86AudioRaiseVolume spawn '${volume_up}'
|
riverctl map $mode None XF86AudioRaiseVolume spawn '${volume_up}'
|
||||||
riverctl map $mode None XF86AudioLowerVolume spawn '${volume_down}'
|
riverctl map $mode None XF86AudioLowerVolume spawn '${volume_down}'
|
||||||
riverctl map $mode None XF86AudioMute spawn '${volume_mute}'
|
riverctl map $mode None XF86AudioMute spawn '${volume_mute}'
|
||||||
|
|
||||||
# Control MPRIS aware media players with playerctl (https://github.com/altdesktop/playerctl)
|
riverctl map $mode None XF86AudioMedia spawn '${media_play}'
|
||||||
riverctl map $mode None XF86AudioMedia spawn '${media_play}'
|
riverctl map $mode None XF86AudioPlay spawn '${media_play}'
|
||||||
riverctl map $mode None XF86AudioPlay spawn '${media_play}'
|
riverctl map $mode None XF86AudioPrev spawn '${media_previous}'
|
||||||
riverctl map $mode None XF86AudioPrev spawn '${media_previous}'
|
riverctl map $mode None XF86AudioNext spawn '${media_next}'
|
||||||
riverctl map $mode None XF86AudioNext spawn '${media_next}'
|
|
||||||
|
|
||||||
# Control screen backlight brightness with brightnessctl (https://github.com/Hummer12007/brightnessctl)
|
riverctl map $mode None XF86MonBrightnessUp spawn '${brightness_up}'
|
||||||
riverctl map $mode None XF86MonBrightnessUp spawn '${brightness_up}'
|
riverctl map $mode None XF86MonBrightnessDown spawn '${brightness_down}'
|
||||||
riverctl map $mode None XF86MonBrightnessDown spawn '${brightness_down}'
|
done
|
||||||
done
|
|
||||||
|
|
||||||
# Set background and border color
|
# Set background and border color
|
||||||
riverctl background-color 0x${border_secondary}
|
riverctl background-color 0x${border_secondary}
|
||||||
riverctl border-color-focused 0x${border_primary}
|
riverctl border-color-focused 0x${border_primary}
|
||||||
riverctl border-color-unfocused 0x${border_inactive}
|
riverctl border-color-unfocused 0x${border_inactive}
|
||||||
|
|
||||||
# Set keyboard repeat rate
|
# Set keyboard repeat rate
|
||||||
riverctl set-repeat 50 300
|
riverctl set-repeat 50 300
|
||||||
|
|
||||||
# Set the default layout generator to be rivertile and start it.
|
# Set the default layout generator to be rivertile and start it.
|
||||||
# River will send the process group of the init executable SIGTERM on exit.
|
# River will send the process group of the init executable SIGTERM on exit.
|
||||||
riverctl default-layout rivertile
|
riverctl default-layout rivertile
|
||||||
rivertile -view-padding 6 -outer-padding 6 &
|
rivertile -view-padding 6 -outer-padding 6 &
|
||||||
|
|
||||||
pkill -f kanshi && kanshi &
|
kanshi &
|
||||||
thunar --daemon &
|
mako &
|
||||||
pkill -f waybar && waybar &
|
nm-applet &
|
||||||
pkill -f nm-applet && nm-applet &
|
swayosd-server &
|
||||||
pkill -f mako && mako
|
thunar --daemon &
|
||||||
pkill -f swayosd-server && swayosd-server &
|
waybar &
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,5 +17,7 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
preset = "framework13.json";
|
preset = "framework13.json";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
desktopEnv.river.enable = true;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue