wrapping should work properly. Probably.

This commit is contained in:
coolnsx
2023-09-02 13:57:54 +05:30
parent eb9ebd3903
commit e6916fe766
21 changed files with 85 additions and 382 deletions

View File

@@ -2,7 +2,7 @@
i=5
while [ $i -gt 0 ];do
notify-send -i "/usr/share/icons/Papirus/16x16/panel/clockify-blue.svg" "$(date)" -h "string:x-canonical-private-synchronous:date" -t 1200 &
notify-send -i "/usr/share/icons/Papirus/16x16/panel/clockify-blue.svg" "$(date)" -h "string:x-canonical-private-synchronous:${0##*/}" -t 1200 &
sleep 1
: $((i-=1))
done

View File

@@ -1,5 +1,5 @@
# See https://wiki.hyprland.org/Configuring/Monitors/
monitor=,highres,auto,1
monitor=,preferred,auto,1
$hypr_dir="$HOME/.config/hypr"
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
@@ -36,11 +36,15 @@ decoration {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
rounding = 10
blur = no
drop_shadow = yes
shadow_range = 4
shadow_render_power = 3
col.shadow = rgba(1a1a1aee)
blur {
enabled = false
size = 8
passes = 2
}
}
animations {
@@ -64,23 +68,12 @@ dwindle {
force_split=2
}
master {
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
new_is_master = true
}
gestures {
# See https://wiki.hyprland.org/Configuring/Variables/ for more
workspace_swipe = true
workspace_swipe_fingers = 3
}
# Example per-device config
# See https://wiki.hyprland.org/Configuring/Keywords/#executing for more
device:epic mouse V1 {
sensitivity = -0.5
}
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
$mainMod = SUPER
@@ -154,6 +147,8 @@ binde=$mainMod, F2, exec, pamixer -d 2 && $hypr_dir/volume #my XF86AudioLowerVol
binde=$mainMod, F3, exec, pamixer -i 2 && $hypr_dir/volume #my XF86AudioLowerVolume doesn't work,So I don't use XF86AudioRaiseVolume, gives me confusion
#binde=, XF86AudioMute, exec, pamixer -t && $hypr_dir/volume #doesn't work either
binde=$mainMod, F8, exec, echo cycle pause | socat - "/tmp/mpvsocket"
binde=, XF86AudioPlay, exec, echo cycle pause | socat - "/tmp/mpvsocket"
binde=, XF86AudioPause, exec, echo cycle pause | socat - "/tmp/mpvsocket"
binde=$mainMod SHIFT, F8, exec, $HOME/repos_scripts/yt-music search_play
binde=$mainMod, F9, exec, $HOME/repos_scripts/yt-music play_next
binde=$mainMod SHIFT, F9, exec, $HOME/repos_scripts/yt-music play_next menu
@@ -168,6 +163,8 @@ windowrulev2=workspace 3,class:^(pcmanfm)$
windowrulev2=workspace 3,class:^(mpv)$
windowrulev2=workspace 3,class:^([c|C]ode)
windowrulev2=workspace 4,class:^(pavucontrol)$
windowrulev2=workspace 4,class:^(Xephyr)$
windowrulev2=fullscreen,class:^(Xephyr)$
#startup applications
exec-once=dbus-update-activation-environment --systemd --all
@@ -176,7 +173,5 @@ exec-once=swaybg -i ~/wall/9.png
exec-once=node ~/arrpc/src > /tmp/discordrpclog
exec-once=xrdb -merge $HOME/.config/.Xresource
exec-once=$hypr_dir/workspace 'focus'
exec-once=eww open-many music_0 time_0
exec-once=sleep 5 && $hypr_dir/workspace
#exec-once=skypeforlinux
exec-once=sleep 2 && google-chrome-stable 'https://web.skype.com/?openPstnPage=true'

View File

@@ -10,7 +10,7 @@ while [ $i -le 5 ];do
vol_stats=$(pamixer --get-mute)
[ "$bat_stats" = "Discharging" ] && bat_icon=🔋 || bat_icon=🔌
[ "$vol_stats" = "true" ] && vol_icon=🔇 || vol_icon=🔊
notify-send -i "lol" "<----------(STATS)---------->" "🧠 CPU usage : $(top -ibn1 | sed -nE 's_%Cpu\(s\):(.*)us.*_\1_p' | cut -d' ' -f2-3) %\n🌡 Cpu Temp : $temp °C\n🔳 RAM : $mem MB / 7733 MB\n$bat_icon Battery : $(cat /sys/class/power_supply/BAT*/capacity) (${bat_stats})\n☀ Brightness : $(light -G | cut -d'.' -f1)%\n$vol_icon Volume : $(pamixer --get-volume-human)\n🎵 $(pgrep -af mpvsocket >/dev/null && cut -d ">" -f1 /tmp/yt-music/current | cut -d":" -f2)" -h "string:x-canonical-private-synchronous:stats" -t 1500 &
notify-send -i "lol" "<----------(STATS)---------->" "🧠 CPU usage : $(top -ibn1 | sed -nE 's_%Cpu\(s\):(.*)us.*_\1_p' | cut -d' ' -f2-3) %\n🌡 Cpu Temp : $temp °C\n🔳 RAM : $mem MB / 7733 MB\n$bat_icon Battery : $(cat /sys/class/power_supply/BAT*/capacity) (${bat_stats})\n☀ Brightness : $(light -G | cut -d'.' -f1)%\n$vol_icon Volume : $(pamixer --get-volume-human)\n🎵 $(pgrep -af mpvsocket >/dev/null && cut -d ">" -f1 /tmp/yt-music/current | cut -d":" -f2)" -h "string:x-canonical-private-synchronous:${0##*/}" -t 1500 &
: $((i+=1))
sleep 1
done

View File

@@ -6,4 +6,4 @@ vol_icon="low"
[ "$vol_int" -gt 33 ] && vol_icon="medium"
[ "$vol_int" -gt 66 ] && vol_icon="high"
pamixer --get-mute | sh && vol_icon="muted"
notify-send -i "/usr/share/icons/Papirus/16x16/panel/audio-volume-$vol_icon.svg" "$vol_int %" -h "string:x-canonical-private-synchronous:volume" -t 1000
notify-send -i "/usr/share/icons/Papirus/16x16/panel/audio-volume-$vol_icon.svg" "$vol_int %" -h "string:x-canonical-private-synchronous:${0##*/}" -t 1000

View File

@@ -6,4 +6,4 @@ else
nmcli radio wifi on
wifi_icon="acquiring"
fi
notify-send -i "/usr/share/icons/Papirus/16x16/panel/network-wireless-$wifi_icon.svg" "wifi $(nmcli radio wifi)" -h "string:x-canonical-private-synchronous:wifi"
notify-send -i "/usr/share/icons/Papirus/16x16/panel/network-wireless-$wifi_icon.svg" "wifi $(nmcli radio wifi)" -h "string:x-canonical-private-synchronous:${0##*/}"

View File

@@ -1,14 +1,14 @@
#!/bin/sh
setup_dual_monitor(){
sed -i "s/monitor=,1920x1080,0x0,1,mirror,eDP-1/monitor=,highres,auto,1/g" "$HOME/.config/hypr/hyprland.conf"
sed -i "s/monitor=,1920x1080,0x0,1,mirror,eDP-1/monitor=,preferred,auto,1/g" "$HOME/.config/hypr/hyprland.conf"
sleep 2
if hyprctl monitors | grep -q "HDMI-A-1";then
notify-send "Setting up dual monitor workflow"
for i in $(seq 2 4);do
hyprctl dispatch moveworkspacetomonitor "$i 0"
done
hyprctl dispatch moveworkspacetomonitor "1 1"
hyprctl dispatch moveworkspacetomonitor "2 1"
hyprctl dispatch moveworkspacetomonitor "3 1"
hyprctl dispatch moveworkspacetomonitor "1 0"
hyprctl dispatch moveworkspacetomonitor "4 0"
eww kill
eww open-many time_1 music_1
fi
@@ -17,12 +17,12 @@ setup_dual_monitor(){
handle_it(){
[ -z "$1" ] || notify-send "$1"
choice=$(printf "Mirror\nExtend" | bemenu --fn 'Roboto 15' -i -c -W 0.2 -B 3 -l 20 -p "what to do??: " -m 1)
[ -z "$choice" ] && exit 0
[ -z "$choice" ] && return 0
notify-send "${choice}ing screen"
if [ "$choice" = "Extend" ];then
setup_dual_monitor
else
sed -i "s/monitor=,highres,auto,1/monitor=,1920x1080,0x0,1,mirror,eDP-1/g" "$HOME/.config/hypr/hyprland.conf"
sed -i "s/monitor=,preferred,auto,1/monitor=,1920x1080,0x0,1,mirror,eDP-1/g" "$HOME/.config/hypr/hyprland.conf"
fi
}
@@ -30,14 +30,14 @@ case $1 in
list)
#only lists the open applications with their workspace number so u can safely close them
for i in $(seq 4);do
notify-send -i "lol" "$(hyprctl clients | sed -nE 's_.*class: ([^ ]*).*_\1_p;s_.*workspace: ([^ ]*).*_workspace \1 : _p' | sed 'N;s/\n/ /')" -h "string:x-canonical-private-synchronous:workspace" -t 1500
notify-send -i "lol" "$(hyprctl clients | sed -nE 's_.*class: ([^ ]*).*_\1_p;s_.*workspace: ([^ ]*).*_workspace \1 : _p' | sed 'N;s/\n/ /')" -h "string:x-canonical-private-synchronous:${0##*/}" -t 1500
sleep 1
done ;;
focus)
#shows the workspace number as notification whenever u switch workspaces and also handles the dual monitor setup on the fly(perfect for laptop users)
socat - "UNIX-CONNECT:/tmp/hypr/$HYPRLAND_INSTANCE_SIGNATURE/.socket2.sock" | while read -r line;do
printf "%s" "$line" | grep -q "monitoradded" && handle_it "$line"
printf "%s" "$line" | grep -q "monitorremoved" && sed -i "s/monitor=,1920x1080,0x0,1,mirror,eDP-1/monitor=,highres,auto,1/g" "$HOME/.config/hypr/hyprland.conf" && eww kill && eww open_many time_0 music_0
printf "%s" "$line" | grep -q "monitorremoved" && sed -i "s/monitor=,1920x1080,0x0,1,mirror,eDP-1/monitor=,preferred,auto,1/g" "$HOME/.config/hypr/hyprland.conf" && eww kill && eww open_many time_0 music_0
#recent workspace switcher
current=$(printf "%s" "$line" | sed -nE 's_^(workspace)>>([^ ]*)_\1 \2_p')
if [ -n "$current" ];then