#! /usr/bin/env bash

hyprctl dispatch togglespecialworkspace music

YT_LINK=$(sort -R < ~/.config/hypr/scripts/music_links.txt | head -n 1)
  
firefox --new-window "$YT_LINK" &
sleep 1
hyprctl dispatch togglefloating
hyprctl dispatch movewindow u
hyprctl dispatch movewindow l
hyprctl dispatch resizeactive exact 45% 45%
hyprctl dispatch moveactive 30% 5%

ghostty ~/.config/hypr/scripts/music_setup_cmd.sh &
sleep 1
hyprctl dispatch togglefloating
hyprctl dispatch resizeactive exact 95% 30%
hyprctl dispatch movewindow d
hyprctl dispatch movewindow l
hyprctl dispatch moveactive -- 30 -5%
