diff --git a/README.md b/README.md index d15dc3d..ded37c7 100644 --- a/README.md +++ b/README.md @@ -7,6 +7,8 @@ The dotfiles are managed with [TOML Bombadil](https://github.com/oknozor/toml-bo ## TODO +* Hyprland + * Start with `uwsm`? * hyprsunset * Ramp throughout day * Wallpaper diff --git a/bombadil.toml b/bombadil.toml index 2588359..a87a197 100644 --- a/bombadil.toml +++ b/bombadil.toml @@ -18,11 +18,10 @@ 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 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" } +# Also needs a `systemctl --user enable --now ip-geolocation.service` and `systemctl --user enable --now sunset.timer` ip-geolocation = { source = "systemd/ip-geolocation.service", target = ".config/systemd/user/ip-geolocation.service" } -swww-daemon = { source = "systemd/swww-daemon.service", target = ".config/systemd/user/swww-daemon.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" } btop = { source = "btop", target = ".config/btop" } dunst = { source = "dunst", target = ".config/dunst" } @@ -40,13 +39,6 @@ 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" ] diff --git a/chonk.toml b/chonk.toml deleted file mode 100644 index 016b94b..0000000 --- a/chonk.toml +++ /dev/null @@ -1,2 +0,0 @@ -[host] -name = "chonk" diff --git a/eww/startup.sh b/eww/startup.sh new file mode 100755 index 0000000..9706527 --- /dev/null +++ b/eww/startup.sh @@ -0,0 +1,12 @@ +#!/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 + diff --git a/hpomen.toml b/hpomen.toml deleted file mode 100644 index 3a35553..0000000 --- a/hpomen.toml +++ /dev/null @@ -1,2 +0,0 @@ -[host] -name = "hpomen" diff --git a/hypr/chonk.conf b/hypr/chonk.conf index 9d2bd7c..69f254d 100644 --- a/hypr/chonk.conf +++ b/hypr/chonk.conf @@ -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,3 +36,6 @@ 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 + diff --git a/hypr/hyprland.conf b/hypr/common.conf similarity index 71% rename from hypr/hyprland.conf rename to hypr/common.conf index d5d3d9c..6729fd4 100644 --- a/hypr/hyprland.conf +++ b/hypr/common.conf @@ -1,14 +1,25 @@ -{% if host.name == "chonk" %} -source = ~/.config/hypr/chonk.conf -{% else %} -source = ~/.config/hypr/hpomen.conf -{% endif %} - -monitor = , preferred, auto, 1 +monitor=,preferred,auto,1 # Set programs that you use -$terminal = uwsm-app -- kitty -$menu = uwsm-app -- env sh ~/.config/rofi/launch.sh +$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 input { kb_layout = us @@ -95,9 +106,9 @@ $mainMod = SUPER bind = SUPER, RETURN, exec, $terminal bind = SUPER SHIFT, Q, killactive, -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 SHIFT, S, exec, ~/scripts/screenshot.sh +bind = SUPER SHIFT, C, exec, hyprpicker -a +bind = SUPER SHIFT, L, exec, swaylock bind = SUPER, F, togglefloating, @@ -142,16 +153,16 @@ bind = $mainMod SHIFT, 0, movetoworkspace, 10 bindm = $mainMod, mouse:272, movewindow bindm = $mainMod, mouse:273, resizewindow -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 = , 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 = , XF86MonBrightnessUp, exec, uwsm-app -- brightnessctl s +5% -bind = , XF86MonBrightnessDown, exec, uwsm-app -- brightnessctl s 5%- +bind = , XF86MonBrightnessUp, exec, brightnessctl s +5% +bind = , XF86MonBrightnessDown, exec, brightnessctl s 5%- -bind = , xf86KbdBrightnessUp, exec, uwsm-app -- brightnessctl -d *::kbd_backlight set +33% -bind = , xf86KbdBrightnessDown, exec, uwsm-app -- brightnessctl -d *::kbd_backlight set 33%- +bind = , xf86KbdBrightnessUp, exec, brightnessctl -d *::kbd_backlight set +33% +bind = , xf86KbdBrightnessDown, exec, brightnessctl -d *::kbd_backlight set 33%- bind=SUPER,R,submap,resize submap=resize @@ -163,5 +174,16 @@ 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 = uwsm-app -- systemctl --user import-environment +exec-once = systemctl --user import-environment +exec-once = /usr/bin/dex -a diff --git a/hypr/hpomen.conf b/hypr/hpomen.conf index 8a072ce..0509d6e 100644 --- a/hypr/hpomen.conf +++ b/hypr/hpomen.conf @@ -1,4 +1,12 @@ -monitor = eDP-1, 1920x1080@60, 0x0, 1 +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 decoration { blur { @@ -32,3 +40,6 @@ gestures { workspace = 1, monitor:eDP-1, default:true workspace = 2, monitor:eDP-1, workspace = 3, monitor:eDP-1, + +source = ~/.config/hypr/common.conf + diff --git a/kitty/kitty.conf b/kitty/kitty.conf index bbc35a9..b753efe 100755 --- a/kitty/kitty.conf +++ b/kitty/kitty.conf @@ -1,4 +1,3 @@ -{% raw %} # vim:fileencoding=utf-8:foldmethod=marker #: Fonts {{{ @@ -2641,4 +2640,3 @@ wayland_enable_ime no #: }}} #: }}} -{% endraw %} diff --git a/rofi/config.rasi b/rofi/config.rasi old mode 100644 new mode 100755 index 3c63950..42dd79d --- a/rofi/config.rasi +++ b/rofi/config.rasi @@ -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}"; } diff --git a/rofi/launch.sh b/rofi/launch.sh index 5a4bff3..193e2be 100755 --- a/rofi/launch.sh +++ b/rofi/launch.sh @@ -1,6 +1,6 @@ #!/bin/env sh hyprctl keyword unbind CONTROL,TAB -rofi -show -#rofi -show drun file-browser-extended calc emoji +rofi -show drun file-browser-extended calc emoji hyprctl keyword bind 'CONTROL,TAB,exec,/home/mbradley/.config/rofi/launch.sh' + diff --git a/systemd/eww-bars.service b/systemd/eww-bars.service deleted file mode 100644 index e959396..0000000 --- a/systemd/eww-bars.service +++ /dev/null @@ -1,19 +0,0 @@ -[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 diff --git a/systemd/eww-daemon.service b/systemd/eww-daemon.service deleted file mode 100644 index f66d8ac..0000000 --- a/systemd/eww-daemon.service +++ /dev/null @@ -1,12 +0,0 @@ -[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 diff --git a/systemd/sunset.service b/systemd/sunset.service new file mode 100644 index 0000000..5579286 --- /dev/null +++ b/systemd/sunset.service @@ -0,0 +1,6 @@ +[Unit] +Description=Reduces blue light + +[Service] +Type=oneshot +ExecStart=hyprsunset -t 3600 diff --git a/systemd/sunset.timer b/systemd/sunset.timer new file mode 100644 index 0000000..bb1b7af --- /dev/null +++ b/systemd/sunset.timer @@ -0,0 +1,10 @@ +[Unit] +Description=Blue light reduction at night +After=graphical.target + +[Timer] +OnCalendar=*-*-* 22:00:00 +Persistent=true + +[Install] +WantedBy=timers.target diff --git a/systemd/swww-daemon.service b/systemd/swww-daemon.service deleted file mode 100644 index 3a3af73..0000000 --- a/systemd/swww-daemon.service +++ /dev/null @@ -1,12 +0,0 @@ -[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 diff --git a/uwsm/env b/uwsm/env deleted file mode 100644 index 3037bf3..0000000 --- a/uwsm/env +++ /dev/null @@ -1,23 +0,0 @@ -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 %} diff --git a/zsh/.p10k-tty.zsh b/zsh/.p10k-tty.zsh index 8e5701a..5202b94 100755 --- a/zsh/.p10k-tty.zsh +++ b/zsh/.p10k-tty.zsh @@ -1,4 +1,3 @@ -{% 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, @@ -1650,4 +1649,3 @@ typeset -g POWERLEVEL9K_CONFIG_FILE=${${(%):-%x}:a} (( ${#p10k_config_opts} )) && setopt ${p10k_config_opts[@]} 'builtin' 'unset' 'p10k_config_opts' -{% endraw %} diff --git a/zsh/.p10k.zsh b/zsh/.p10k.zsh index 4764d82..c5dda32 100755 --- a/zsh/.p10k.zsh +++ b/zsh/.p10k.zsh @@ -1,4 +1,3 @@ -{% 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, @@ -1651,4 +1650,3 @@ typeset -g POWERLEVEL9K_CONFIG_FILE=${${(%):-%x}:a} (( ${#p10k_config_opts} )) && setopt ${p10k_config_opts[@]} 'builtin' 'unset' 'p10k_config_opts' -{% endraw %}