fix: concat audio and brightness, add notifications
This commit is contained in:
parent
63c6e4214e
commit
64fe6f4e84
14 changed files with 185 additions and 71 deletions
54
eww/eww.scss
54
eww/eww.scss
|
|
@ -69,6 +69,15 @@ tooltip label {
|
||||||
background-image: linear-gradient(to right, #e4c9af 30%, #f2cdcd 50%, #e0b089 100% *50);
|
background-image: linear-gradient(to right, #e4c9af 30%, #f2cdcd 50%, #e0b089 100% *50);
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
}
|
}
|
||||||
|
.brightbar scale trough {
|
||||||
|
all: unset;
|
||||||
|
box-shadow: 0 6px 5px 2px #06060b;
|
||||||
|
background-color: #232232;
|
||||||
|
border-radius: 24px;
|
||||||
|
min-height: 10px;
|
||||||
|
min-width: 100px;
|
||||||
|
margin : 0px -15px 5px 0px;
|
||||||
|
}
|
||||||
.volbar trough highlight {
|
.volbar trough highlight {
|
||||||
background-image: linear-gradient(to right, #afcee0 30%, #a1bdce 50%, #77a5bf 100% *50);
|
background-image: linear-gradient(to right, #afcee0 30%, #a1bdce 50%, #77a5bf 100% *50);
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
|
|
@ -81,7 +90,14 @@ tooltip label {
|
||||||
.bright_icon {
|
.bright_icon {
|
||||||
font-size: 22;
|
font-size: 22;
|
||||||
color: #e4c9af;
|
color: #e4c9af;
|
||||||
margin: 0px 10px 0px 0px;
|
margin: 0px 10px 0px -10px;
|
||||||
|
}
|
||||||
|
.bright_icon_overlay {
|
||||||
|
font-size: 28;
|
||||||
|
color: #e4c9af;
|
||||||
|
background-size: cover;
|
||||||
|
background-position: center;
|
||||||
|
margin: 0px 27px 0px 3px;
|
||||||
}
|
}
|
||||||
.volume_icon {
|
.volume_icon {
|
||||||
font-size: 22;
|
font-size: 22;
|
||||||
|
|
@ -382,26 +398,32 @@ color: #bfc9db;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
background-image: url('images/speaker.png');
|
background-image: url('images/speaker.png');
|
||||||
background-position: center;
|
background-position: center;
|
||||||
min-height: 70px;
|
min-height: 40px;
|
||||||
min-width: 75px;
|
min-width: 45px;
|
||||||
margin: 10px 20px 5px 20px;
|
margin: 10px 10px 5px 20px;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.speaker_text {
|
.speaker_text {
|
||||||
color: #a1bdce;
|
color: #a1bdce;
|
||||||
font-size : 26px;
|
font-size : 22px;
|
||||||
font-weight : bold;
|
font-weight : bold;
|
||||||
margin: 20px 0px 0px 0px;
|
margin: 5px 15px 0px 15px;
|
||||||
|
}
|
||||||
|
.bright_text {
|
||||||
|
color: #a1bdce;
|
||||||
|
font-size : 22px;
|
||||||
|
font-weight : bold;
|
||||||
|
margin: 5px 15px 0px 25px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.change_audio_box {
|
.change_audio_box {
|
||||||
margin: 0px 0px 0px 100px;
|
margin: 0px 0px 0px 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.change_audio {
|
.change_audio {
|
||||||
color: #a1bdce;
|
color: #a1bdce;
|
||||||
margin: 0px 30px 5px 0px;
|
margin: 0px 50px 0px 50px;
|
||||||
font-size: 30px;
|
font-size: 30px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
@ -416,8 +438,8 @@ color: #bfc9db;
|
||||||
background-color: #232232;
|
background-color: #232232;
|
||||||
box-shadow: 0 6px 5px 2px #06060b;
|
box-shadow: 0 6px 5px 2px #06060b;
|
||||||
border-radius: 24px;
|
border-radius: 24px;
|
||||||
min-height: 13px;
|
min-height: 10px;
|
||||||
min-width: 120px;
|
min-width: 100px;
|
||||||
margin : 0px 0px 5px 0px;
|
margin : 0px 0px 5px 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -428,9 +450,9 @@ color: #bfc9db;
|
||||||
background-size: cover;
|
background-size: cover;
|
||||||
background-image: url('images/mic.png');
|
background-image: url('images/mic.png');
|
||||||
background-position: center;
|
background-position: center;
|
||||||
min-height: 70px;
|
min-height: 40px;
|
||||||
min-width: 75px;
|
min-width: 45px;
|
||||||
margin: 5px 20px 20px 20px;
|
margin: 5px 20px 20px 10px;
|
||||||
border-radius: 12px;
|
border-radius: 12px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -451,9 +473,9 @@ color: #bfc9db;
|
||||||
box-shadow: 0 6px 5px 2px #06060b;
|
box-shadow: 0 6px 5px 2px #06060b;
|
||||||
background-color: #232232;
|
background-color: #232232;
|
||||||
border-radius: 24px;
|
border-radius: 24px;
|
||||||
min-height: 13px;
|
min-height: 10px;
|
||||||
min-width: 120px;
|
min-width: 100px;
|
||||||
margin : 0px 0px 20px 0px;
|
margin :6px 0px 20px 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.audio_sep {
|
.audio_sep {
|
||||||
|
|
|
||||||
114
eww/eww.yuck
114
eww/eww.yuck
|
|
@ -4,8 +4,8 @@
|
||||||
(defpoll clock_date :interval "10h" "date '+%d/%m'")
|
(defpoll clock_date :interval "10h" "date '+%d/%m'")
|
||||||
|
|
||||||
;; volume definitions ;;
|
;; volume definitions ;;
|
||||||
(defpoll volume_percent :interval "3s" "pactl get-sink-volume @DEFAULT_SINK@ | awk -F '/' ' { print $2 } ' | tr -d ' %'")
|
(defpoll volume_percent :interval "1s" "pactl get-sink-volume @DEFAULT_SINK@ | awk -F '/' ' { print $2 } ' | tr -d ' %'")
|
||||||
(defpoll mic_percent :interval "3s" "pactl get-source-volume @DEFAULT_SOURCE@ | awk -F'/' '{ print $2 }' | tr -d ' %'")
|
(defpoll mic_percent :interval "1s" "pactl get-source-volume @DEFAULT_SOURCE@ | awk -F'/' '{ print $2 }' | tr -d ' %'")
|
||||||
(defpoll brightness_percent :interval "5s" "brightnessctl -m -d intel_backlight | awk -F, '{print substr($4, 0, length($4)-1)}' | tr -d '%'")
|
(defpoll brightness_percent :interval "5s" "brightnessctl -m -d intel_backlight | awk -F, '{print substr($4, 0, length($4)-1)}' | tr -d '%'")
|
||||||
|
|
||||||
;; battery definitions ;;
|
;; battery definitions ;;
|
||||||
|
|
@ -121,45 +121,61 @@
|
||||||
clock_date
|
clock_date
|
||||||
)))))
|
)))))
|
||||||
|
|
||||||
;; speaker and mic volume ;;
|
;; speaker volume ;;
|
||||||
(defwidget volume []
|
(defwidget volume []
|
||||||
(eventbox :onhover "${eww} update vol_reveal=true"
|
;;(eventbox :onhover "${eww} update vol_reveal=true"
|
||||||
:onhoverlost "${eww} update vol_reveal=false"
|
;; :onhoverlost "${eww} update vol_reveal=false"
|
||||||
(box :class "module-2" :space-evenly "false" :orientation "h" :spacing "3"
|
(box :class "module-2" :space-evenly "false" :orientation "h" :spacing "3"
|
||||||
(button :onclick "scripts/pop audio" :class "volume_icon" "")
|
(button :onclick "scripts/pop audio" :class "volume_icon" "")))
|
||||||
(revealer :transition "slideleft"
|
;;(revealer :transition "slideleft"
|
||||||
:reveal vol_reveal
|
;; :reveal vol_reveal
|
||||||
:duration "350ms"
|
;; :duration "350ms"
|
||||||
(scale :class "volbar"
|
;;(scale :class "volbar"
|
||||||
:value volume_percent
|
;; :value volume_percent
|
||||||
:orientation "h"
|
;; :orientation "h"
|
||||||
:tooltip "${volume_percent}%"
|
;; :tooltip "${volume_percent}%"
|
||||||
:max 100
|
;; :max 100
|
||||||
:min 0
|
;; :min 0
|
||||||
:onchange "pactl set-sink-volume @DEFAULT_SINK@ {}%" )))))
|
;; :onchange "scripts/change-volume sink {}%" )))
|
||||||
|
|
||||||
;; screen brightness ;;
|
;; screen brightness ;;
|
||||||
(defwidget bright []
|
(defwidget bright []
|
||||||
(eventbox :onhover "${eww} update br_reveal=true" :onhoverlost "${eww} update br_reveal=false"
|
;;(eventbox :onhover "${eww} update br_reveal=true" :onhoverlost "${eww} update br_reveal=false"
|
||||||
(box :class "module-2" :space-evenly "false" :orientation "h" :spacing "3"
|
(box :class "module-2" :space-evenly "false" :orientation "h" :spacing "3"
|
||||||
(label :text "" :class "bright_icon" :tooltip "brightness")
|
(button :onclick "scripts/pop brightness" :class "bright_icon" "")))
|
||||||
(revealer :transition "slideleft"
|
;;(revealer :transition "slideleft"
|
||||||
:reveal br_reveal
|
;; :reveal br_reveal
|
||||||
:duration "350ms"
|
;; :duration "350ms"
|
||||||
(scale :class "brightbar"
|
;; (scale :class "brightbar"
|
||||||
:value brightness_percent
|
;; :value brightness_percent
|
||||||
|
;; :orientation "h"
|
||||||
|
;; :tooltip "${brightness_percent}%"
|
||||||
|
;; :max 100
|
||||||
|
;; :min 0
|
||||||
|
;; :onchange "brightnessctl set {}%" )))
|
||||||
|
|
||||||
|
;; brightness widget ;;
|
||||||
|
(defwidget brightness_overlay []
|
||||||
|
(eventbox :onhover "scripts/pop hoverCreate"
|
||||||
|
:onhoverlost "scripts/pop hoverGet brightness_window"
|
||||||
|
(box :class "audio-box" :halign "center" :orientation "v" :vexpand "false" :hexpand "false"
|
||||||
|
(label :class "speaker_text" :text "brightness" :halign "left" )
|
||||||
|
(box :class "brightbar" :halign "center" :vexpand "false" :hexpand "false"
|
||||||
|
(label :class "bright_icon_overlay" :text "")
|
||||||
|
(scale :value brightness_percent
|
||||||
|
:space-evenly "false"
|
||||||
:orientation "h"
|
:orientation "h"
|
||||||
:tooltip "${brightness_percent}%"
|
:onchange "brightnessctl set {}%"
|
||||||
|
:tooltip "brightness on ${brightness_percent}%"
|
||||||
:max 100
|
:max 100
|
||||||
:min 0
|
:min 0)))))
|
||||||
:onchange "brightnessctl set {}%" )))))
|
|
||||||
|
|
||||||
;; audio volume widget ;;
|
;; audio volume widget ;;
|
||||||
(defwidget audio []
|
(defwidget audio []
|
||||||
(eventbox :onhover "scripts/pop hoverCreate"
|
(eventbox :onhover "scripts/pop hoverCreate"
|
||||||
:onhoverlost "scripts/pop hoverGet audio_ctl"
|
:onhoverlost "scripts/pop hoverGet audio_ctl"
|
||||||
(box :class "audio-box" :orientation "v" :space-evenly "false" :vexpand "false" :hexpand "false"
|
(box :class "audio-box" :orientation "v" :space-evenly "false" :vexpand "false" :hexpand "false"
|
||||||
(box :halign "v" :space-evenly "false" :hexpand "false" :vexpand "false"
|
(box :halign "center" :space-evenly "false" :hexpand "false" :vexpand "false"
|
||||||
(box :class "speaker_icon" :orientation "v")
|
(box :class "speaker_icon" :orientation "v")
|
||||||
(box :orientation "v" :halign "center" :vexpand "false" :hexpand "false"
|
(box :orientation "v" :halign "center" :vexpand "false" :hexpand "false"
|
||||||
(label :class "speaker_text" :text "speaker" :valign "center" :halign "left" )
|
(label :class "speaker_text" :text "speaker" :valign "center" :halign "left" )
|
||||||
|
|
@ -167,28 +183,41 @@
|
||||||
(scale :value volume_percent
|
(scale :value volume_percent
|
||||||
:space-evenly "false"
|
:space-evenly "false"
|
||||||
:orientation "h"
|
:orientation "h"
|
||||||
:onchange "pactl set-sink-volume @DEFAULT_SINK@ {}%"
|
:onchange "pactl set-sink-volume @DEFAULT_SINK@ {}%"
|
||||||
:tooltip "volume on ${volume_percent}%"
|
:tooltip "volume on ${volume_percent}%"
|
||||||
:max 100
|
:max 100
|
||||||
:min 0))))
|
:min 0))))
|
||||||
(label :text "" :class "audio_sep" :halign "center")
|
(label :text "" :class "audio_sep" :halign "center")
|
||||||
(box :halign "v" :space-evenly "false" :hexpand "false" :vexpand "false"
|
(box :halign "center" :space-evenly "false" :hexpand "false" :vexpand "false"
|
||||||
(box :class "mic_icon" :orientation "v")
|
(box :class "mic_icon" :orientation "v")
|
||||||
(box :orientation "v" :halign "center" :vexpand "false" :hexpand "false"
|
(box :orientation "v" :halign "center" :vexpand "false" :hexpand "false"
|
||||||
(label :class "mic_text" :text "mic" :valign "center" :halign "left" )
|
(label :class "speaker_text" :text "mic" :valign "center" :halign "left" )
|
||||||
(box :class "mic_bar" :halign "center" :vexpand "false" :hexpand "false"
|
(box :class "mic_bar" :halign "center" :vexpand "false" :hexpand "false"
|
||||||
(scale :value mic_percent
|
(scale :value mic_percent
|
||||||
:space-evenly "false"
|
:space-evenly "false"
|
||||||
:orientation "h"
|
:orientation "h"
|
||||||
:tooltip "mic on ${mic_percent}%"
|
:tooltip "mic on ${mic_percent}%"
|
||||||
:onchange "pactl set-source-volume @DEFAULT_SOURCE@ {}%"
|
:onchange "pactl set-source-volume @DEFAULT_SOURCE@ {}%"
|
||||||
:max 100
|
:max 100
|
||||||
:min 0))))
|
:min 0))))
|
||||||
(label :text "" :class "audio_sep" :halign "center")
|
(label :text "" :class "audio_sep" :halign "center")
|
||||||
(box :class "change_audio_box" :halign "v" :space-evenly "false" :hexpand "false" :vexpand "false"
|
(box :halign "center" :space-evenly "false" :hexpand "false" :vexpand "false"
|
||||||
(box :class "change_audio" :orientation "v"
|
(label :class "bright_icon_overlay" :orientation "v" :text "")
|
||||||
|
(box :orientation "v" :halign "center" :vexpand "false" :hexpand "false"
|
||||||
|
(label :class "bright_text" :text "lux" :valign "center" :halign "right" )
|
||||||
|
(box :class "brightbar" :halign "center" :vexpand "false" :hexpand "false"
|
||||||
|
(scale :value brightness_percent
|
||||||
|
:space-evenly "false"
|
||||||
|
:orientation "h"
|
||||||
|
:tooltip "brightness ${brightness_percent}%"
|
||||||
|
:onchange "brightnessctl set {}%"
|
||||||
|
:max 100
|
||||||
|
:min 0))))
|
||||||
|
(label :text "" :class "audio_sep" :halign "center")
|
||||||
|
(box :class "change_audio_box" :halign "center" :spac`e-evenly "false" :hexpand "false" :vexpand "false"
|
||||||
|
(box :class "change_audio" :orientation "v" :halign "left"
|
||||||
(button :onclick "scripts/change-audio internal" ""))
|
(button :onclick "scripts/change-audio internal" ""))
|
||||||
(box :class "change_audio" :orientation "v"
|
(box :class "change_audio" :orientation "v" :halign "right"
|
||||||
(button :onclick "scripts/change-audio bluetooth" ""))
|
(button :onclick "scripts/change-audio bluetooth" ""))
|
||||||
))))
|
))))
|
||||||
|
|
||||||
|
|
@ -304,7 +333,6 @@
|
||||||
:space-evenly false
|
:space-evenly false
|
||||||
:halign "end"
|
:halign "end"
|
||||||
:class "left_modules"
|
:class "left_modules"
|
||||||
(bright)
|
|
||||||
(volume)
|
(volume)
|
||||||
(wifi)
|
(wifi)
|
||||||
(bluetooth)
|
(bluetooth)
|
||||||
|
|
@ -353,6 +381,16 @@
|
||||||
(cal))
|
(cal))
|
||||||
|
|
||||||
(defwindow audio_ctl
|
(defwindow audio_ctl
|
||||||
|
:monitor 0
|
||||||
|
:geometry (geometry :x "120px"
|
||||||
|
:y "2px"
|
||||||
|
:anchor "top right"
|
||||||
|
:width "250px"
|
||||||
|
:height "330px")
|
||||||
|
:stacking "overlay"
|
||||||
|
(audio))
|
||||||
|
|
||||||
|
(defwindow brightness_window
|
||||||
:monitor 0
|
:monitor 0
|
||||||
:geometry (geometry :x "250px"
|
:geometry (geometry :x "250px"
|
||||||
:y "2px"
|
:y "2px"
|
||||||
|
|
@ -360,7 +398,7 @@
|
||||||
:width "280px"
|
:width "280px"
|
||||||
:height "60px")
|
:height "60px")
|
||||||
:stacking "overlay"
|
:stacking "overlay"
|
||||||
(audio))
|
(brightness_overlay))
|
||||||
|
|
||||||
;; music again .. ;;
|
;; music again .. ;;
|
||||||
;; (defwindow music_win :stacking "fg" :focusable "false" :screen 1
|
;; (defwindow music_win :stacking "fg" :focusable "false" :screen 1
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
bat=/sys/class/power_supply/BAT0/
|
bat=/sys/class/power_supply/BAT0/
|
||||||
per="$(cat "$bat/capacity")"
|
per="$(cat "$bat/capacity")"
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#! /bin/sh
|
#! /bin/bash
|
||||||
|
|
||||||
internal() {
|
internal() {
|
||||||
SPEAKER=$(pactl list sinks | grep "Name" | grep "alsa" | awk -F ': ' '{ print $2 }')
|
SPEAKER=$(pactl list sinks | grep "Name" | grep "alsa" | awk -F ': ' '{ print $2 }')
|
||||||
|
|
|
||||||
12
eww/scripts/change-brightness
Executable file
12
eww/scripts/change-brightness
Executable file
|
|
@ -0,0 +1,12 @@
|
||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
set_brightness() {
|
||||||
|
brightnessctl set "$1"
|
||||||
|
CURRENT=$(brightnessctl -m -d intel_backlight | awk -F, '{print substr($4, 0, length($4)-1)}')
|
||||||
|
dunstify -a "changeBrightness" -r 3 -u low -i brightness-high -h int:value:"$CURRENT" "Brightness: ${CURRENT}%"
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ "$1" == "brightness" ]; then
|
||||||
|
set_brightness "$2"
|
||||||
|
fi
|
||||||
|
|
||||||
20
eww/scripts/change-volume
Executable file
20
eww/scripts/change-volume
Executable file
|
|
@ -0,0 +1,20 @@
|
||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
set_volume_sink() {
|
||||||
|
pactl set-sink-volume @DEFAULT_SINK@ "$1"
|
||||||
|
CURRENT=$(pactl get-sink-volume @DEFAULT_SINK@ | awk -F'/' '{ print $2 }' | tr -d ' %')
|
||||||
|
dunstify -a "changeVolume" -r 2 -u low -i audio-volume-high -h int:value:"$CURRENT" "Output Volume: ${CURRENT}%"
|
||||||
|
}
|
||||||
|
|
||||||
|
set_volume_source() {
|
||||||
|
pactl set-source-volume @DEFAULT_SOURCE@ "$1"
|
||||||
|
CURRENT=$(pactl get-source-volume @DEFAULT_SOURCE@ | awk -F'/' '{ print $2 }' | tr -d ' %')
|
||||||
|
dunstify -a "changeMicVolume" -r 2 -u low -i audio-volume-high -h int:value:"$CURRENT" "Input Volume: ${CURRENT}%"
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if [ "$1" == "sink" ]; then
|
||||||
|
set_volume_sink "$2"
|
||||||
|
elif [ "$1" == "source" ]; then
|
||||||
|
set_volume_source "$2"
|
||||||
|
fi
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
currentName() {
|
currentName() {
|
||||||
win=$(hyprctl activewindow | grep class | awk -F ':' '{print $2}' | tr -d ' ')
|
win=$(hyprctl activewindow | grep class | awk -F ':' '{print $2}' | tr -d ' ')
|
||||||
echo "(box :class \"module_app_text\" :space-evenly \"false\" :orientation \"h\" :spacing \"3\" (label :text \"$win\"))"
|
echo "(box :class \"module_app_text\" :space-evenly \"false\" :orientation \"h\" :spacing \"3\" (label :text \"$win\"))"
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
|
|
||||||
total="$(free -m | grep Mem: | awk '{ print $2 }')"
|
total="$(free -m | grep Mem: | awk '{ print $2 }')"
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,3 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
printf "%.0f\n" $(free -m | grep Mem | awk '{print ($3/$2)*100}')
|
printf "%.0f\n" $(free -m | grep Mem | awk '{print ($3/$2)*100}')
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
# scripts by adi1090x
|
# scripts by adi1090x
|
||||||
|
|
||||||
## Get data
|
## Get data
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
|
|
||||||
calendar() {
|
calendar() {
|
||||||
|
|
@ -11,7 +11,7 @@ run() {
|
||||||
|
|
||||||
# Open widgets
|
# Open widgets
|
||||||
if [[ ! -f "$LOCK_FILE" ]]; then
|
if [[ ! -f "$LOCK_FILE" ]]; then
|
||||||
${EWW_BIN} -c $HOME/.config/eww close system music_win audio_ctl
|
${EWW_BIN} -c $HOME/.config/eww close system music_win audio_ctl brightness
|
||||||
touch "$LOCK_FILE"
|
touch "$LOCK_FILE"
|
||||||
run && echo "ok good!"
|
run && echo "ok good!"
|
||||||
else
|
else
|
||||||
|
|
@ -31,7 +31,7 @@ run() {
|
||||||
|
|
||||||
# Open widgets
|
# Open widgets
|
||||||
if [[ ! -f "$LOCK_FILE_MEM" ]]; then
|
if [[ ! -f "$LOCK_FILE_MEM" ]]; then
|
||||||
${EWW_BIN} -c $HOME/.config/eww close calendar music_win audio_ctl
|
${EWW_BIN} -c $HOME/.config/eww close calendar music_win audio_ctl brightness
|
||||||
touch "$LOCK_FILE_MEM"
|
touch "$LOCK_FILE_MEM"
|
||||||
run && echo "ok good!"
|
run && echo "ok good!"
|
||||||
else
|
else
|
||||||
|
|
@ -51,7 +51,7 @@ run() {
|
||||||
|
|
||||||
# Open widgets
|
# Open widgets
|
||||||
if [[ ! -f "$LOCK_FILE_SONG" ]]; then
|
if [[ ! -f "$LOCK_FILE_SONG" ]]; then
|
||||||
${EWW_BIN} -c $HOME/.config/eww close system calendar
|
${EWW_BIN} -c $HOME/.config/eww close system calendar brightness
|
||||||
touch "$LOCK_FILE_SONG"
|
touch "$LOCK_FILE_SONG"
|
||||||
run && echo "ok good!"
|
run && echo "ok good!"
|
||||||
else
|
else
|
||||||
|
|
@ -72,7 +72,7 @@ run() {
|
||||||
|
|
||||||
# Open widgets
|
# Open widgets
|
||||||
if [[ ! -f "$LOCK_FILE_AUDIO" ]]; then
|
if [[ ! -f "$LOCK_FILE_AUDIO" ]]; then
|
||||||
${EWW_BIN} -c $HOME/.config/eww close system calendar music
|
${EWW_BIN} -c $HOME/.config/eww close system calendar music brightness
|
||||||
touch "$LOCK_FILE_AUDIO"
|
touch "$LOCK_FILE_AUDIO"
|
||||||
run && echo "ok good!"
|
run && echo "ok good!"
|
||||||
else
|
else
|
||||||
|
|
@ -81,6 +81,25 @@ else
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
brightness() {
|
||||||
|
LOCK_FILE_AUDIO="$HOME/.cache/eww-brightness.lock"
|
||||||
|
EWW_BIN="$HOME/.local/bin/eww"
|
||||||
|
|
||||||
|
run() {
|
||||||
|
${EWW_BIN} -c $HOME/.config/eww open brightness_window
|
||||||
|
}
|
||||||
|
|
||||||
|
# Open widgets
|
||||||
|
if [[ ! -f "$LOCK_FILE_AUDIO" ]]; then
|
||||||
|
${EWW_BIN} -c $HOME/.config/eww close system calendar music audio_ctl
|
||||||
|
touch "$LOCK_FILE_AUDIO"
|
||||||
|
run && echo "ok good!"
|
||||||
|
else
|
||||||
|
${EWW_BIN} -c $HOME/.config/eww close brightness_window
|
||||||
|
rm "$LOCK_FILE_AUDIO" && echo "closed"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
hoverGet() {
|
hoverGet() {
|
||||||
NAME="$1"
|
NAME="$1"
|
||||||
EWW_BIN="$HOME/.local/bin/eww"
|
EWW_BIN="$HOME/.local/bin/eww"
|
||||||
|
|
@ -106,6 +125,8 @@ elif [ "$1" = "system" ]; then
|
||||||
#music
|
#music
|
||||||
elif [ "$1" = "audio" ]; then
|
elif [ "$1" = "audio" ]; then
|
||||||
audio
|
audio
|
||||||
|
elif [ "$1" = "brightness" ]; then
|
||||||
|
brightness
|
||||||
elif [ "$1" = "hoverGet" ]; then
|
elif [ "$1" = "hoverGet" ]; then
|
||||||
hoverGet "$2"
|
hoverGet "$2"
|
||||||
elif [ "$1" = "hoverCreate" ]; then
|
elif [ "$1" = "hoverCreate" ]; then
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
|
|
||||||
status=$(nmcli g | grep -oE "disconnected")
|
status=$(nmcli g | grep -oE "disconnected")
|
||||||
essid=$(nmcli c | grep wlp2s0 | awk '{print ($1)}')
|
essid=$(nmcli c | grep wlp2s0 | awk '{print ($1)}')
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/sh
|
#!/bin/bash
|
||||||
workspaces() {
|
workspaces() {
|
||||||
|
|
||||||
ws1="ID 1"
|
ws1="ID 1"
|
||||||
|
|
|
||||||
|
|
@ -78,6 +78,7 @@ misc {
|
||||||
# for windows named/classed as abc and xyz
|
# for windows named/classed as abc and xyz
|
||||||
windowrule=tile,^(.*)(Spotify)(.*)$
|
windowrule=tile,^(.*)(Spotify)(.*)$
|
||||||
windowrule=center,^(.*)$
|
windowrule=center,^(.*)$
|
||||||
|
windowrule=opacity 80,^(.*)(dunst)(.*)$
|
||||||
#windowrule=tile,xyz
|
#windowrule=tile,xyz
|
||||||
#windowrule=float,abc
|
#windowrule=float,abc
|
||||||
#windowrule=pseudo,abc
|
#windowrule=pseudo,abc
|
||||||
|
|
@ -95,13 +96,13 @@ bind=SUPER,R,exec,wofi --show drun -o DP-3
|
||||||
bind=SUPER,C,togglesplit
|
bind=SUPER,C,togglesplit
|
||||||
bind=SUPERSHIFT,L,exec, playerctl -a pause & swaylock -c 000000 & systemctl suspend
|
bind=SUPERSHIFT,L,exec, playerctl -a pause & swaylock -c 000000 & systemctl suspend
|
||||||
bind=,XF86AudioMute,exec,pactl set-sink-mute @DEFAULT_SINK@ toggle
|
bind=,XF86AudioMute,exec,pactl set-sink-mute @DEFAULT_SINK@ toggle
|
||||||
bind=,XF86AudioLowerVolume,exec,pactl set-sink-volume @DEFAULT_SINK@ -5%
|
bind=,XF86AudioLowerVolume,exec, $HOME/.config/eww/scripts/change-volume sink -5%
|
||||||
bind=,XF86AudioRaiseVolume,exec,pactl set-sink-volume @DEFAULT_SINK@ +5%
|
bind=,XF86AudioRaiseVolume,exec, $HOME/.config/eww/scripts/change-volume sink +5%
|
||||||
bind=,XF86AudioPlay,exec, playerctl play-pause
|
bind=,XF86AudioPlay,exec, playerctl play-pause
|
||||||
bind=,XF86AudioNext,exec, playerctl next
|
bind=,XF86AudioNext,exec, playerctl next
|
||||||
bind=,XF86AudioPrev,exec, playerctl previous
|
bind=,XF86AudioPrev,exec, playerctl previous
|
||||||
bind=,XF86MonBrightnessDown,exec, brightnessctl set 10%-
|
bind=,XF86MonBrightnessDown,exec, $HOME/.config/eww/scripts/change-brightness brightness 10%-
|
||||||
bind=,XF86MonBrightnessUp,exec, brightnessctl set +10%
|
bind=,XF86MonBrightnessUp,exec, $HOME/.config/eww/scripts/change-brightness brightness +10%
|
||||||
|
|
||||||
|
|
||||||
bind=SUPER,bracketleft,movefocus,l
|
bind=SUPER,bracketleft,movefocus,l
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue