Compare commits

...

3 commits

Author SHA1 Message Date
dcc74af714
Start Hyprland using uwsm
Still a few broken bits to get working again (1Password on startup,
hyprsunset control), but the important stuff is functional
2025-03-25 00:32:06 -04:00
66c5bad209
Use Tera syntax to simplify Hyprland startup 2025-03-24 22:45:44 -04:00
380aab25a8
Add Tera raw directives to avoid templating issues 2025-03-24 22:12:53 -04:00
19 changed files with 114 additions and 96 deletions

View file

@ -7,8 +7,6 @@ The dotfiles are managed with [TOML Bombadil](https://github.com/oknozor/toml-bo
## TODO
* Hyprland
* Start with `uwsm`?
* hyprsunset
* Ramp throughout day
* Wallpaper

View file

@ -18,10 +18,11 @@ discord = { source = "config/electron-flags.conf", target = ".config/discord-fla
git = { source = "git/config", target = ".config/git/config" }
# Also needs a `systemctl --user enable --now ip-geolocation.service` and `systemctl --user enable --now sunset.timer`
# Also needs a `systemctl --user enable --now eww-daemon.service eww-bars.service ip-geolocation.service swww-daemon.service'
eww-daemon = { source = "systemd/eww-daemon.service", target = ".config/systemd/user/eww-daemon.service" }
eww-bars = { source = "systemd/eww-bars.service", target = ".config/systemd/user/eww-bars.service" }
ip-geolocation = { source = "systemd/ip-geolocation.service", target = ".config/systemd/user/ip-geolocation.service" }
sunset-timer = { source = "systemd/sunset.timer", target = ".config/systemd/user/sunset.timer" }
sunset-service = { source = "systemd/sunset.service", target = ".config/systemd/user/sunset.service" }
swww-daemon = { source = "systemd/swww-daemon.service", target = ".config/systemd/user/swww-daemon.service" }
btop = { source = "btop", target = ".config/btop" }
dunst = { source = "dunst", target = ".config/dunst" }
@ -39,6 +40,13 @@ lvim = { source = "lvim/config.lua", target = ".config/lvim/config.lua" }
rofi = { source = "rofi", target = ".config/rofi" }
steam = { source = "steam/steam_dev.cfg", target = ".steam/steam/steam_dev.cfg" }
swaylock = { source = "swaylock", target = ".config/swaylock" }
uwsm = { source = "uwsm", target = ".config/uwsm" }
vim = { source = "vim/vimrc", target = ".config/vim/vimrc" }
yazi = { source = "yazi", target = ".config/yazi" }
zsh = { source = "zsh", target = ".config/zsh" }
[profiles.chonk]
vars = [ "chonk.toml" ]
[profiles.hpomen]
vars = [ "hpomen.toml" ]

2
chonk.toml Normal file
View file

@ -0,0 +1,2 @@
[host]
name = "chonk"

View file

@ -1,12 +0,0 @@
#!/bin/env sh
source ~/scripts/env_vars.sh
eww daemon
if [ "$(uname -n)" = "chonk" ]; then
eww open-many left right
else
eww open laptop
fi

2
hpomen.toml Normal file
View file

@ -0,0 +1,2 @@
[host]
name = "hpomen"

View file

@ -1,5 +1,5 @@
monitor=DP-1,1920x1080@165,1920x0,1
monitor=DP-2,1920x1080@165,0x0,1
monitor = DP-1, 1920x1080@165, 1920x0, 1
monitor = DP-2, 1920x1080@165, 0x0, 1
decoration {
blur {
@ -36,6 +36,3 @@ workspace = 7, monitor:DP-2
workspace = 8, monitor:DP-1
workspace = 9, monitor:DP-2
workspace = 10, monitor:DP-1
source = ~/.config/hypr/common.conf

View file

@ -1,12 +1,4 @@
monitor=eDP-1,1920x1080@60,0x0,1
env = GBM_BACKEND,nvidia-drm
env = __GLX_VENDOR_LIBRARY_NAME,nvidia
env = LIBVA_DRIVER_NAME,nvidia
env = __GL_VRR_ALLOWED,0
env = WLR_NO_HARDWARE_CURSORS,1
env = NVD_BACKEND,direct
monitor = eDP-1, 1920x1080@60, 0x0, 1
decoration {
blur {
@ -40,6 +32,3 @@ gestures {
workspace = 1, monitor:eDP-1, default:true
workspace = 2, monitor:eDP-1,
workspace = 3, monitor:eDP-1,
source = ~/.config/hypr/common.conf

View file

@ -1,25 +1,14 @@
monitor=,preferred,auto,1
{% if host.name == "chonk" %}
source = ~/.config/hypr/chonk.conf
{% else %}
source = ~/.config/hypr/hpomen.conf
{% endif %}
monitor = , preferred, auto, 1
# Set programs that you use
$terminal = kitty
$menu = /home/mbradley/.config/rofi/launch.sh
env = XCURSOR_SIZE,24
env = GDK_BACKEND,wayland,x11,*
env = SDL_VIDEODRIVER,wayland
env = CLUTTER_BACKEND,wayland
env = XDG_CURRENT_DESKTOP,Hyprland
env = XDG_SESSION_TYPE,wayland
env = XDG_SESSION_DESKTOP,Hyprland
env = QT_AUTO_SCREEN_SCALE_FACTOR,1
env = QT_QPA_PLATFORM,wayland;xcb
env = QT_WAYLAND_DISABLE_WINDOWDECORATION,1
env = QT_QPA_PLATFORMTHEME,qt6ct
env = ELECTRON_OZONE_PLATFORM_HINT,wayland
$terminal = uwsm-app -- kitty
$menu = uwsm-app -- env sh ~/.config/rofi/launch.sh
input {
kb_layout = us
@ -106,9 +95,9 @@ $mainMod = SUPER
bind = SUPER, RETURN, exec, $terminal
bind = SUPER SHIFT, Q, killactive,
bind = SUPER SHIFT, S, exec, ~/scripts/screenshot.sh
bind = SUPER SHIFT, C, exec, hyprpicker -a
bind = SUPER SHIFT, L, exec, swaylock
bind = SUPER SHIFT, S, exec, uwsm-app -- env sh ~/scripts/screenshot.sh
bind = SUPER SHIFT, C, exec, uwsm-app -- hyprpicker -a
bind = SUPER SHIFT, L, exec, uwsm-app -- swaylock
bind = SUPER, F, togglefloating,
@ -153,16 +142,16 @@ bind = $mainMod SHIFT, 0, movetoworkspace, 10
bindm = $mainMod, mouse:272, movewindow
bindm = $mainMod, mouse:273, resizewindow
bind = , XF86AudioRaiseVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ +5%
bind = , XF86AudioLowerVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ -5%
bind = , XF86AudioMute, exec, pactl set-sink-mute @DEFAULT_SINK@ toggle
bind = , XF86AudioMicMute, exec, pactl set-source-mute @DEFAULT_SOURCE@ toggle
bind = , XF86AudioRaiseVolume, exec, uwsm-app -- pactl set-sink-volume @DEFAULT_SINK@ +5%
bind = , XF86AudioLowerVolume, exec, uwsm-app -- pactl set-sink-volume @DEFAULT_SINK@ -5%
bind = , XF86AudioMute, exec, uwsm-app -- pactl set-sink-mute @DEFAULT_SINK@ toggle
bind = , XF86AudioMicMute, exec, uwsm-app -- pactl set-source-mute @DEFAULT_SOURCE@ toggle
bind = , XF86MonBrightnessUp, exec, brightnessctl s +5%
bind = , XF86MonBrightnessDown, exec, brightnessctl s 5%-
bind = , XF86MonBrightnessUp, exec, uwsm-app -- brightnessctl s +5%
bind = , XF86MonBrightnessDown, exec, uwsm-app -- brightnessctl s 5%-
bind = , xf86KbdBrightnessUp, exec, brightnessctl -d *::kbd_backlight set +33%
bind = , xf86KbdBrightnessDown, exec, brightnessctl -d *::kbd_backlight set 33%-
bind = , xf86KbdBrightnessUp, exec, uwsm-app -- brightnessctl -d *::kbd_backlight set +33%
bind = , xf86KbdBrightnessDown, exec, uwsm-app -- brightnessctl -d *::kbd_backlight set 33%-
bind=SUPER,R,submap,resize
submap=resize
@ -174,16 +163,5 @@ bind=,escape,submap,reset
bind=SUPER,R,submap,reset
submap=reset
exec-once = ~/.config/eww/startup.sh
exec-once = swww-daemon
exec-once = ydotoold
exec-once = dunst
exec-once = /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
exec-once = 1password --silent
exec = ~/scripts/swww_set.py
exec = dunstctl reload
exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP HYPRLAND_INSTANCE_SIGNATURE
exec-once = systemctl --user import-environment
exec-once = /usr/bin/dex -a
exec-once = uwsm-app -- systemctl --user import-environment

View file

@ -1,3 +1,4 @@
{% raw %}
# vim:fileencoding=utf-8:foldmethod=marker
#: Fonts {{{
@ -2640,3 +2641,4 @@ wayland_enable_ime no
#: }}}
#: }}}
{% endraw %}

2
rofi/config.rasi Executable file → Normal file
View file

@ -1,7 +1,7 @@
@theme "arthuredit"
configuration {
modi: "drun,calc,emoji:/usr/bin/rofimoji -a copy -f emojis math,audio:/home/mbradley/dev/rofi-audio/rofi-audio.py";
combi-modi: "drun,filebrowser,emoji";
icon-theme: "Papirus";
show-icons: true;
run-command: "uwsm-app -- {cmd}";
}

View file

@ -1,6 +1,6 @@
#!/bin/env sh
hyprctl keyword unbind CONTROL,TAB
rofi -show drun file-browser-extended calc emoji
rofi -show
#rofi -show drun file-browser-extended calc emoji
hyprctl keyword bind 'CONTROL,TAB,exec,/home/mbradley/.config/rofi/launch.sh'

19
systemd/eww-bars.service Normal file
View file

@ -0,0 +1,19 @@
[Unit]
Description=My custom status bar(s)
After=graphical-session.target
After=swww-daemon.service
Requires=eww-daemon.service
[Service]
Type=exec
{% if host.name == "chonk" %}
ExecStart=eww open-many left right
{% else %}
ExecStart=eww open laptop
{% endif %}
ExecCondition=/lib/systemd/systemd-xdg-autostart-condition "Hyprland" ""
Restart=on-failure
Slice=background-graphical.slice
[Install]
WantedBy=graphical-session.target

View file

@ -0,0 +1,12 @@
[Unit]
Description=Daemon for my custom status bar(s)
After=graphical-session.target
[Service]
Type=exec
ExecStart=eww daemon --no-daemonize
Restart=on-failure
Slice=background-graphical.slice
[Install]
WantedBy=graphical-session.target

View file

@ -1,6 +0,0 @@
[Unit]
Description=Reduces blue light
[Service]
Type=oneshot
ExecStart=hyprsunset -t 3600

View file

@ -1,10 +0,0 @@
[Unit]
Description=Blue light reduction at night
After=graphical.target
[Timer]
OnCalendar=*-*-* 22:00:00
Persistent=true
[Install]
WantedBy=timers.target

View file

@ -0,0 +1,12 @@
[Unit]
Description=Daemon to display desktop wallpapers
After=graphical-session.target
[Service]
Type=exec
ExecStart=swww-daemon
Restart=on-failure
Slice=background-graphical.slice
[Install]
WantedBy=graphical-session.target

23
uwsm/env Normal file
View file

@ -0,0 +1,23 @@
export GTK_THEME=Adwaita:dark
export XCURSOR_SIZE=24
export GDK_BACKEND=wayland,x11,*
export SDL_VIDEODRIVER,wayland
export CLUTTER_BACKEND,wayland
export QT_AUTO_SCREEN_SCALE_FACTOR=1
export QT_QPA_PLATFORM=wayland;xcb
export QT_WAYLAND_DISABLE_WINDOWDECORATION=1
export QT_QPA_PLATFORMTHEME=qt6ct
export ELECTRON_OZONE_PLATFORM_HINT=wayland
{% if host.name == "hpomen" %}
export GBM_BACKEND=nvidia-drm
export __GLX_VENDOR_LIBRARY_NAME=nvidia
export LIBVA_DRIVER_NAME=nvidia
export __GL_VRR_ALLOWED=0
export WLR_NO_HARDWARE_CURSORS=1
export NVD_BACKEND=direct
{% endif %}

View file

@ -1,3 +1,4 @@
{% raw %}
# Generated by Powerlevel10k configuration wizard on 2023-01-09 at 19:29 EST.
# Based on romkatv/powerlevel10k/config/p10k-lean-8colors.zsh, checksum 54735.
# Wizard options: ascii, lean_8colors, 24h time, 2 lines, solid, white-ornaments,
@ -1649,3 +1650,4 @@ typeset -g POWERLEVEL9K_CONFIG_FILE=${${(%):-%x}:a}
(( ${#p10k_config_opts} )) && setopt ${p10k_config_opts[@]}
'builtin' 'unset' 'p10k_config_opts'
{% endraw %}

View file

@ -1,3 +1,4 @@
{% raw %}
# Generated by Powerlevel10k configuration wizard on 2022-08-20 at 20:39 EDT.
# Based on romkatv/powerlevel10k/config/p10k-classic.zsh, checksum 62739.
# Wizard options: nerdfont-complete + powerline, small icons, classic, unicode, darkest,
@ -1650,3 +1651,4 @@ typeset -g POWERLEVEL9K_CONFIG_FILE=${${(%):-%x}:a}
(( ${#p10k_config_opts} )) && setopt ${p10k_config_opts[@]}
'builtin' 'unset' 'p10k_config_opts'
{% endraw %}