Merge remote-tracking branch 'origin/main'
This commit is contained in:
commit
494d70558c
5 changed files with 16 additions and 17 deletions
16
eww/eww.yuck
16
eww/eww.yuck
|
@ -42,56 +42,56 @@
|
|||
:widgetclass "cpu"
|
||||
:hover "${round(EWW_CPU.avg, 1)}%"
|
||||
:percentage {round(EWW_CPU.avg, 1)}
|
||||
:image "images/cpu.png"))
|
||||
:image "../images/cpu.png"))
|
||||
|
||||
(defwidget ram []
|
||||
(icon
|
||||
:widgetclass "ram"
|
||||
:hover "${round(EWW_RAM.used_mem /(1024*1024*1024), 1)} GiB | ${round(EWW_RAM.used_mem_perc, 1)}%"
|
||||
:percentage {round(EWW_RAM.used_mem_perc, 1)}
|
||||
:image "images/ram.png"))
|
||||
:image "../images/ram.png"))
|
||||
|
||||
(defwidget audio []
|
||||
(icon
|
||||
:widgetclass {volume.muted == 1 ? "muted" : "volume"}
|
||||
:hover "${volume.volume}%"
|
||||
:percentage {volume.volume >= 0 && volume.volume <= 100 ? volume.volume : 0}
|
||||
:image {volume.muted == 1 ? "images/volumeMuted.png" : "images/volume.png"}))
|
||||
:image {volume.muted == 1 ? "../images/volumeMuted.png" : "../images/volume.png"}))
|
||||
|
||||
(defwidget brightness []
|
||||
(icon
|
||||
:widgetclass "brightness"
|
||||
:hover "${brightnessValue / 960}%"
|
||||
:percentage {brightnessValue / 960}
|
||||
:image "images/brightness.png"))
|
||||
:image "../images/brightness.png"))
|
||||
|
||||
(defwidget network []
|
||||
(icon
|
||||
:widgetclass "network"
|
||||
:hover {network.name}
|
||||
:percentage "100"
|
||||
:image "images/${network.image}.png"))
|
||||
:image "../images/${network.image}.png"))
|
||||
|
||||
(defwidget bluetooth []
|
||||
(icon
|
||||
:widgetclass "bluetooth"
|
||||
:hover {bluetooth.name}
|
||||
:percentage {bluetooth.battery}
|
||||
:image "images/bluetooth.png"))
|
||||
:image "../images/bluetooth.png"))
|
||||
|
||||
(defwidget battery []
|
||||
(icon
|
||||
:widgetclass {EWW_BATTERY.BAT1.status == "Charging" ? "battery" : EWW_BATTERY.total_avg > 25 ? "battery" : "batteryLow"}
|
||||
:hover "${round(EWW_BATTERY.total_avg, 1)}%"
|
||||
:percentage {EWW_BATTERY.total_avg <= 90 ? round(EWW_BATTERY.total_avg, 1)/0.9 : 100}
|
||||
:image {EWW_BATTERY.BAT1.status == "Charging" ? "images/charging.png" : EWW_BATTERY.total_avg > 25 ? "images/battery.png" : "images/batteryLow.png"}))
|
||||
:image {EWW_BATTERY.BAT1.status == "Charging" ? "../images/charging.png" : EWW_BATTERY.total_avg > 25 ? "../images/battery.png" : "../images/batteryLow.png"}))
|
||||
|
||||
(defwidget power []
|
||||
(icon
|
||||
:widgetclass "power"
|
||||
:hover "placeholder"
|
||||
:percentage "0"
|
||||
:image "images/power.png"))
|
||||
:image "../images/power.png"))
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -1,25 +1,25 @@
|
|||
(deflisten brightnessValue
|
||||
:initial "0"
|
||||
`scripts/brightness.sh`)
|
||||
`../scripts/brightness.sh`)
|
||||
|
||||
(deflisten network
|
||||
:initial '{"name":"No Connection","image":"n.A."}'
|
||||
`sh scripts/network.sh`)
|
||||
`../scripts/network.sh`)
|
||||
|
||||
(deflisten workspaces
|
||||
:initial ''
|
||||
`scripts/clients/build/clients`)
|
||||
`../scripts/client`)
|
||||
|
||||
(defpoll bluetooth
|
||||
:initial '{"name":"","battery":"0"}'
|
||||
:interval "2s"
|
||||
`sh scripts/bluetooth.sh`)
|
||||
`../scripts/bluetooth.sh`)
|
||||
|
||||
(deflisten volume
|
||||
:initial '{"volume":"0","muted":"0"}'
|
||||
`sh scripts/volume.sh`)
|
||||
`../scripts/volume.sh`)
|
||||
|
||||
(defpoll media
|
||||
:initial '{"status":"","name":""}'
|
||||
:interval "2s"
|
||||
`scripts/media.sh`)
|
||||
`../scripts/media.sh`)
|
||||
|
|
|
@ -244,8 +244,7 @@ int main(int argc, char const *argv[])
|
|||
getAllWorkspaces();
|
||||
std::cout << workspacesOutput << std::endl;
|
||||
|
||||
std::string socketPath = "/tmp/hypr/" + std::string(std::getenv("HYPRLAND_INSTANCE_SIGNATURE")) + "/.socket2.sock";
|
||||
|
||||
std::string socketPath = std::string(std::getenv("XDG_RUNTIME_DIR")) + "/hypr/" + std::string(std::getenv("HYPRLAND_INSTANCE_SIGNATURE")) + "/.socket2.sock";
|
||||
|
||||
// Create a socket
|
||||
int sockfd = socket(AF_UNIX, SOCK_STREAM, 0);
|
||||
|
|
|
@ -35,6 +35,6 @@ for ((i = 0; i < ${#id[@]}; i++)); do
|
|||
|
||||
monitorID=$(xrandr --listactivemonitors | grep +"${name[$i]}" | awk '{sub(/.$/,"",$1); print $1}')
|
||||
|
||||
eww open bar --id bar"${monitorID}" --arg monitor="${monitorID}" --arg width="${new_width}" --arg height=30
|
||||
eww open bar --id bar"${monitorID}" --arg monitor="${monitorID}" --arg width="${new_width}" --arg height=30 --config ../eww
|
||||
sleep 2
|
||||
done
|
||||
|
|
BIN
scripts/client
Executable file
BIN
scripts/client
Executable file
Binary file not shown.
Loading…
Add table
Reference in a new issue