make directories implicit
							
								
								
									
										532
									
								
								eww/eww.yuck
									
										
									
									
									
								
							
							
						
						|  | @ -12,79 +12,79 @@ | |||
| 
 | ||||
| 
 | ||||
| (defwidget normalWorkspaces [monitor] | ||||
|     (box | ||||
|         :space-evenly false | ||||
|         :spacing 3 | ||||
|         :valign "center" | ||||
|         :height 20 | ||||
|         (for workspace in workspaces | ||||
|             (workspace | ||||
|                 :activeOn {workspace.normal.activeOn} | ||||
|                 :occupied {workspace.normal.occupied} | ||||
|                 :id {workspace.normal.id} | ||||
|                 :cmd {workspace.normal.id} | ||||
|                 :icon {workspace.normal.icon} | ||||
|                 :monitor {monitor})))) | ||||
|   (box | ||||
|     :space-evenly false | ||||
|     :spacing 3 | ||||
|     :valign "center" | ||||
|     :height 20 | ||||
|     (for workspace in workspaces | ||||
|       (workspace | ||||
|         :activeOn {workspace.normal.activeOn} | ||||
|         :occupied {workspace.normal.occupied} | ||||
|         :id {workspace.normal.id} | ||||
|         :cmd {workspace.normal.id} | ||||
|         :icon {workspace.normal.icon} | ||||
|       :monitor {monitor})))) | ||||
| 
 | ||||
| 
 | ||||
| ;; right | ||||
| 
 | ||||
| 
 | ||||
| (defwidget cpu [] | ||||
|     (icon | ||||
|         :widgetclass "cpu" | ||||
|         :hover "${round(EWW_CPU.avg, 1)}%" | ||||
|         :percentage {round(EWW_CPU.avg, 1)} | ||||
|         :image "../images/cpu.png")) | ||||
|   (icon | ||||
|     :widgetclass "cpu" | ||||
|     :hover "${round(EWW_CPU.avg, 1)}%" | ||||
|     :percentage {round(EWW_CPU.avg, 1)} | ||||
|   :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")) | ||||
|   (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")) | ||||
| 
 | ||||
| (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"})) | ||||
|   (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"})) | ||||
| 
 | ||||
| (defwidget brightness [] | ||||
|     (icon | ||||
|         :widgetclass "brightness" | ||||
|         :hover "${brightnessValue / 960}%" | ||||
|         :percentage {brightnessValue / 960} | ||||
|         :image "../images/brightness.png")) | ||||
|   (icon | ||||
|     :widgetclass "brightness" | ||||
|     :hover "${brightnessValue / 960}%" | ||||
|     :percentage {brightnessValue / 960} | ||||
|   :image "./images/brightness.png")) | ||||
| 
 | ||||
| (defwidget network [] | ||||
|     (icon | ||||
|         :widgetclass "network" | ||||
|         :hover {network.name} | ||||
|         :percentage "100" | ||||
|         :image "../images/${network.image}.png")) | ||||
|   (icon | ||||
|     :widgetclass "network" | ||||
|     :hover {network.name} | ||||
|     :percentage "100" | ||||
|   :image "./images/${network.image}.png")) | ||||
| 
 | ||||
| (defwidget bluetooth [] | ||||
|     (icon | ||||
|         :widgetclass "bluetooth" | ||||
|         :hover {bluetooth.name} | ||||
|         :percentage {bluetooth.battery} | ||||
|         :image "../images/bluetooth.png")) | ||||
|   (icon | ||||
|     :widgetclass "bluetooth" | ||||
|     :hover {bluetooth.name} | ||||
|     :percentage {bluetooth.battery} | ||||
|   :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"})) | ||||
|   (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"})) | ||||
| 
 | ||||
| (defwidget power [] | ||||
|     (icon | ||||
|         :widgetclass "power" | ||||
|         :hover "placeholder" | ||||
|         :percentage "0" | ||||
|         :image "../images/power.png")) | ||||
|   (icon | ||||
|     :widgetclass "power" | ||||
|     :hover "placeholder" | ||||
|     :percentage "0" | ||||
|   :image "./images/power.png")) | ||||
| 
 | ||||
| 
 | ||||
| 
 | ||||
|  | @ -92,243 +92,243 @@ | |||
| ;; Widget blocks | ||||
| 
 | ||||
| (defwidget media [] | ||||
|         (box | ||||
|             :class "smallBox" | ||||
|             :height 20 | ||||
|             :valign "center" | ||||
|             :spacing 1 | ||||
|             :space-evenly false | ||||
|             (space) | ||||
|             (label | ||||
|                 :text "${media.title} - ${media.artist}" | ||||
|                 :tooltip "${media.title} - ${media.artist} | ${media.album}" | ||||
|                 :truncate true) | ||||
|             (space))) | ||||
|   (box | ||||
|     :class "smallBox" | ||||
|     :height 20 | ||||
|     :valign "center" | ||||
|     :spacing 1 | ||||
|     :space-evenly false | ||||
|     (space) | ||||
|     (label | ||||
|       :text "${media.title} - ${media.artist}" | ||||
|       :tooltip "${media.title} - ${media.artist} | ${media.album}" | ||||
|     :truncate true) | ||||
|     (space))) | ||||
| 
 | ||||
| (defwidget processing [] | ||||
|     (eventbox | ||||
|         :onclick 'hyprctl dispatch exec "[float; pin; size 40% 40%; move 100%-41% 40] kitty bpytop -b proc"' | ||||
|         :class "smallBox" | ||||
|         :halign "end" | ||||
|         :valign "center" | ||||
|         :height 20 | ||||
|         (box | ||||
|             :space-evenly false | ||||
|             :halign "end" | ||||
|             :valign "center" | ||||
|             :height 20 | ||||
|             (smallSpacer) | ||||
|             (cpu) | ||||
|             (space) | ||||
|             (ram) | ||||
|             (smallSpacer)))) | ||||
|   (eventbox | ||||
|     :onclick 'hyprctl dispatch exec "[float; pin; size 40% 40%; move 100%-41% 40] kitty bpytop -b proc"' | ||||
|     :class "smallBox" | ||||
|     :halign "end" | ||||
|     :valign "center" | ||||
|     :height 20 | ||||
|     (box | ||||
|       :space-evenly false | ||||
|       :halign "end" | ||||
|       :valign "center" | ||||
|       :height 20 | ||||
|       (smallSpacer) | ||||
|       (cpu) | ||||
|       (space) | ||||
|       (ram) | ||||
|       (smallSpacer)))) | ||||
| 
 | ||||
| (defwidget controlls [] | ||||
|     (eventbox | ||||
|         :onclick 'hyprctl dispatch exec "[float; pin; size 40% 40%; move 100%-41% 40] kitty pulsemixer"' | ||||
|         :class "smallBox" | ||||
|         :halign "end" | ||||
|         :valign "center" | ||||
|         :height 20 | ||||
|         (box | ||||
|             :space-evenly false | ||||
|             :halign "end" | ||||
|             :valign "center" | ||||
|             :height 20 | ||||
|             (smallSpacer) | ||||
|             (audio) | ||||
|             (space) | ||||
|             (brightness) | ||||
|             (smallSpacer)))) | ||||
|   (eventbox | ||||
|     :onclick 'hyprctl dispatch exec "[float; pin; size 40% 40%; move 100%-41% 40] kitty pulsemixer"' | ||||
|     :class "smallBox" | ||||
|     :halign "end" | ||||
|     :valign "center" | ||||
|     :height 20 | ||||
|     (box | ||||
|       :space-evenly false | ||||
|       :halign "end" | ||||
|       :valign "center" | ||||
|       :height 20 | ||||
|       (smallSpacer) | ||||
|       (audio) | ||||
|       (space) | ||||
|       (brightness) | ||||
|       (smallSpacer)))) | ||||
| 
 | ||||
| (defwidget wireless [] | ||||
|     (eventbox | ||||
|         :onclick "`networkmanager_dmenu`" | ||||
|         :class "smallBox" | ||||
|         :halign "end" | ||||
|         :valign "center" | ||||
|         :height 20 | ||||
|         (box | ||||
|             :space-evenly false | ||||
|             :halign "end" | ||||
|             :valign "center" | ||||
|             :height 24 | ||||
|             (smallSpacer) | ||||
|             (network) | ||||
|             (space) | ||||
|             (bluetooth) | ||||
|             (smallSpacer)))) | ||||
|   (eventbox | ||||
|     :onclick "`networkmanager_dmenu`" | ||||
|     :class "smallBox" | ||||
|     :halign "end" | ||||
|     :valign "center" | ||||
|     :height 20 | ||||
|     (box | ||||
|       :space-evenly false | ||||
|       :halign "end" | ||||
|       :valign "center" | ||||
|       :height 24 | ||||
|       (smallSpacer) | ||||
|       (network) | ||||
|       (space) | ||||
|       (bluetooth) | ||||
|       (smallSpacer)))) | ||||
| 
 | ||||
| (defwidget energy [] | ||||
|     (eventbox | ||||
|         :onclick `wlogout -r 25 -c 25 -m 300 &` | ||||
|         :class "smallBox" | ||||
|         :valign "center" | ||||
|         :height 20 | ||||
|         (box | ||||
|             :space-evenly false | ||||
|             :halign "end" | ||||
|             :valign "center" | ||||
|             :height 20 | ||||
|             (smallSpacer) | ||||
|             (battery) | ||||
|             (space) | ||||
|             (power) | ||||
|             (smallSpacer)))) | ||||
|   (eventbox | ||||
|     :onclick `wlogout -r 25 -c 25 -m 300 &` | ||||
|     :class "smallBox" | ||||
|     :valign "center" | ||||
|     :height 20 | ||||
|     (box | ||||
|       :space-evenly false | ||||
|       :halign "end" | ||||
|       :valign "center" | ||||
|       :height 20 | ||||
|       (smallSpacer) | ||||
|       (battery) | ||||
|       (space) | ||||
|       (power) | ||||
|       (smallSpacer)))) | ||||
| 
 | ||||
| ;; Boxes | ||||
| 
 | ||||
| (defwidget timeBox [] | ||||
|     (box | ||||
|         :class "barbox" | ||||
|         :spacing 3 | ||||
|         :space-evenly false | ||||
|         :halign "end" | ||||
|         :valign "center" | ||||
|         :height 30 | ||||
|         (space) | ||||
|         (testtime) | ||||
|         (space))) | ||||
|   (box | ||||
|     :class "barbox" | ||||
|     :spacing 3 | ||||
|     :space-evenly false | ||||
|     :halign "end" | ||||
|     :valign "center" | ||||
|     :height 30 | ||||
|     (space) | ||||
|     (testtime) | ||||
|     (space))) | ||||
| 
 | ||||
| (defwidget mediaBox [] | ||||
|     (box | ||||
|         :class "barbox" | ||||
|         :visible {media.status == "Playing" ? true : false} | ||||
|         :spacing 3 | ||||
|         :space-evenly false | ||||
|         :halign "end" | ||||
|         :valign "center" | ||||
|         :height 30 | ||||
|             (space) | ||||
|             (media) | ||||
|             (space))) | ||||
|   (box | ||||
|     :class "barbox" | ||||
|     :visible {media.status == "Playing" ? true : false} | ||||
|     :spacing 3 | ||||
|     :space-evenly false | ||||
|     :halign "end" | ||||
|     :valign "center" | ||||
|     :height 30 | ||||
|     (space) | ||||
|     (media) | ||||
|     (space))) | ||||
| 
 | ||||
| 
 | ||||
| (defwidget start [] | ||||
|     (box | ||||
|         :orientation "h" | ||||
|         :space-evenly false | ||||
|         :height  30 | ||||
|         :halign "start" | ||||
|         :valign "center" | ||||
|         :spacing 3 | ||||
|         (timeBox) | ||||
|         (mediaBox) | ||||
|         (box))) | ||||
|   (box | ||||
|     :orientation "h" | ||||
|     :space-evenly false | ||||
|     :height  30 | ||||
|     :halign "start" | ||||
|     :valign "center" | ||||
|     :spacing 3 | ||||
|     (timeBox) | ||||
|     (mediaBox) | ||||
|     (box))) | ||||
| 
 | ||||
| (defwidget center [monitor] | ||||
|     (box | ||||
| 	:class "barbox" | ||||
|         :orientation "h" | ||||
|         :space-evenly false | ||||
|         :spacing 3 | ||||
|         :height  30 | ||||
|         :halign "center" | ||||
|         :valign "center" | ||||
|         (space) | ||||
|         (workspace | ||||
|             :activeOn {workspaces[0].special.activeOn} | ||||
|             :occupied {workspaces[0].special.occupied} | ||||
|             :id {workspaces[0].special.id} | ||||
|             :icon {workspaces[0].special.icon} | ||||
|             :monitor {monitor}) | ||||
|         (workspace | ||||
|             :activeOn {workspaces[1].special.activeOn} | ||||
|             :occupied {workspaces[1].special.occupied} | ||||
|             :id {workspaces[1].special.id} | ||||
|             :icon {workspaces[1].special.icon} | ||||
|             :monitor {monitor}) | ||||
|             (seperator) | ||||
|         (normalWorkspaces | ||||
|             :monitor {monitor}) | ||||
|         (seperator) | ||||
|         (workspace | ||||
|             :activeOn {workspaces[2].special.activeOn} | ||||
|             :occupied {workspaces[2].special.occupied} | ||||
|             :id {workspaces[2].special.id} | ||||
|             :icon {workspaces[2].special.icon} | ||||
|             :monitor {monitor}) | ||||
|         (workspace | ||||
|             :activeOn {workspaces[3].special.activeOn} | ||||
|             :occupied {workspaces[3].special.occupied} | ||||
|             :id {workspaces[3].special.id} | ||||
|             :icon {workspaces[3].special.icon} | ||||
|             :monitor {monitor}) | ||||
|         (space))) | ||||
|   (box | ||||
|     :class "barbox" | ||||
|     :orientation "h" | ||||
|     :space-evenly false | ||||
|     :spacing 3 | ||||
|     :height  30 | ||||
|     :halign "center" | ||||
|     :valign "center" | ||||
|     (space) | ||||
|     (workspace | ||||
|       :activeOn {workspaces[0].special.activeOn} | ||||
|       :occupied {workspaces[0].special.occupied} | ||||
|       :id {workspaces[0].special.id} | ||||
|       :icon {workspaces[0].special.icon} | ||||
|     :monitor {monitor}) | ||||
|     (workspace | ||||
|       :activeOn {workspaces[1].special.activeOn} | ||||
|       :occupied {workspaces[1].special.occupied} | ||||
|       :id {workspaces[1].special.id} | ||||
|       :icon {workspaces[1].special.icon} | ||||
|     :monitor {monitor}) | ||||
|     (seperator) | ||||
|     (normalWorkspaces | ||||
|     :monitor {monitor}) | ||||
|     (seperator) | ||||
|     (workspace | ||||
|       :activeOn {workspaces[2].special.activeOn} | ||||
|       :occupied {workspaces[2].special.occupied} | ||||
|       :id {workspaces[2].special.id} | ||||
|       :icon {workspaces[2].special.icon} | ||||
|     :monitor {monitor}) | ||||
|     (workspace | ||||
|       :activeOn {workspaces[3].special.activeOn} | ||||
|       :occupied {workspaces[3].special.occupied} | ||||
|       :id {workspaces[3].special.id} | ||||
|       :icon {workspaces[3].special.icon} | ||||
|     :monitor {monitor}) | ||||
|     (space))) | ||||
| 
 | ||||
| (defwidget end [] | ||||
|   (box | ||||
|     :orientation "h" | ||||
|     :space-evenly false | ||||
|     :spacing 3 | ||||
|     :height  30 | ||||
|     :valign "center" | ||||
|     :halign "end" | ||||
|     (box | ||||
|         :orientation "h" | ||||
|         :space-evenly false | ||||
|         :spacing 3 | ||||
|         :height  30 | ||||
|         :valign "center" | ||||
|         :halign "end" | ||||
|         (box | ||||
|             :class "barbox" | ||||
|             :space-evenly false | ||||
|             :spacing 2 | ||||
|             (space) | ||||
|             (testtime | ||||
|                 :timezone "US/Eastern" | ||||
|                 :image "../images/USTime.png") | ||||
|             (seperator) | ||||
|             (testtime | ||||
|                 :timezone "Asia/Seoul" | ||||
|                 :image "../images/SamGuk-by_Sang_Min.png") | ||||
|             (space)) | ||||
|         (box | ||||
| 	    :class "barbox" | ||||
|             :spacing 2 | ||||
|             :orientation "h" | ||||
|             :space-evenly false | ||||
|             :height  30 | ||||
|             :valign "center" | ||||
|             :halign "end" | ||||
|              | ||||
|             (space) | ||||
| ;;            (systray | ||||
| ;;                :spacing 2 | ||||
| ;;                :orientation "h" | ||||
| ;;                :space-evenly true | ||||
| ;;                :icon-size 16) | ||||
| ;;   | ||||
| ;;            (seperator) | ||||
| 
 | ||||
|             (processing) | ||||
| 
 | ||||
|             (seperator) | ||||
|              | ||||
|             (controlls) | ||||
| 
 | ||||
|             (seperator) | ||||
| 
 | ||||
|             (wireless) | ||||
| 
 | ||||
|             (seperator) | ||||
| 
 | ||||
|             (energy) | ||||
| 
 | ||||
|             (space)))) | ||||
|       :class "barbox" | ||||
|       :space-evenly false | ||||
|       :spacing 2 | ||||
|       (space) | ||||
|       (testtime | ||||
|         :timezone "US/Eastern" | ||||
|       :image "./images/USTime.png") | ||||
|       (seperator) | ||||
|       (testtime | ||||
|         :timezone "Asia/Seoul" | ||||
|       :image "./images/SamGuk-by_Sang_Min.png") | ||||
|       (space)) | ||||
|     (box | ||||
|       :class "barbox" | ||||
|       :spacing 2 | ||||
|       :orientation "h" | ||||
|       :space-evenly false | ||||
|       :height  30 | ||||
|       :valign "center" | ||||
|       :halign "end" | ||||
|        | ||||
|       (space) | ||||
|       ;;            (systray | ||||
|         ;;                :spacing 2 | ||||
|         ;;                :orientation "h" | ||||
|         ;;                :space-evenly true | ||||
|       ;;                :icon-size 16) | ||||
|       ;; | ||||
|       ;;            (seperator) | ||||
|        | ||||
|       (processing) | ||||
|        | ||||
|       (seperator) | ||||
|        | ||||
|       (controlls) | ||||
|        | ||||
|       (seperator) | ||||
|        | ||||
|       (wireless) | ||||
|        | ||||
|       (seperator) | ||||
|        | ||||
|       (energy) | ||||
|        | ||||
|       (space)))) | ||||
| 
 | ||||
| (defwidget bar [monitor] | ||||
|     (centerbox | ||||
|         :orientation "h" | ||||
|         (start) | ||||
|         (center | ||||
|             :monitor {monitor}) | ||||
|         (end))) | ||||
|   (centerbox | ||||
|     :orientation "h" | ||||
|     (start) | ||||
|     (center | ||||
|     :monitor {monitor}) | ||||
|     (end))) | ||||
| 
 | ||||
| 
 | ||||
| (defwindow bar [monitor width height] | ||||
|     :monitor {monitor} | ||||
|     :geometry (geometry | ||||
|         :x "0%" | ||||
|         :y "5px" | ||||
|         :width "${width}px" | ||||
|         :height "${height}px" | ||||
|         :anchor "top center") | ||||
|     :stacking "fg" | ||||
|     :exclusive true | ||||
|     (bar | ||||
|         :monitor {monitor})) | ||||
|   :monitor {monitor} | ||||
|   :geometry (geometry | ||||
|     :x "0%" | ||||
|     :y "5px" | ||||
|     :width "${width}px" | ||||
|     :height "${height}px" | ||||
|   :anchor "top center") | ||||
|   :stacking "fg" | ||||
|   :exclusive true | ||||
|   (bar | ||||
|   :monitor {monitor})) | ||||
|  |  | |||
							
								
								
									
										
											BIN
										
									
								
								eww/images/Bob Ross.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 734 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/SamGuk-by_Sang_Min.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 27 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/USTime.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 31 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/battery.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 11 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/batteryLow.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 11 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/bluetooth.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 25 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/bluetoothOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 19 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/brightness.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 18 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/brightnessOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 13 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/charging.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 14 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/chargingOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 11 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/cpu.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 14 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/cpuOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 10 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/ethernet.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 7.9 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/ethernetOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 4.3 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/hibernate.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 18 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/lock.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 7.9 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/logout.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 6.2 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/power.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 18 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/powerOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 8.8 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/ram.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 8.3 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/ramOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 4.5 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/reboot.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 16 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/shutdown.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 15 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/suspend.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 17 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/test.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 20 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/volume.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 15 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/volumeMuted.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 14 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/volumeOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 10 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/wifiHigh.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 20 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/wifiLow.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 9.7 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/wifiMedium.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 14 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/wifiOriginal.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 15 KiB | 
							
								
								
									
										
											BIN
										
									
								
								eww/images/wifiVeryLow.png
									
										
									
									
									
										Normal file
									
								
							
							
						
						| After Width: | Height: | Size: 6.9 KiB | 
							
								
								
									
										23
									
								
								eww/scripts/bluetooth.sh
									
										
									
									
									
										Executable file
									
								
							
							
						
						|  | @ -0,0 +1,23 @@ | |||
| #!/usr/bin/env bash | ||||
| 
 | ||||
| # Get the list of connected Bluetooth devices | ||||
| devices=$(bluetoothctl devices Connected | awk '{print $2}') | ||||
| name[0]="" | ||||
| battery[0]=0 | ||||
| i=0 | ||||
| # Iterate through each device and get its name and battery percentage | ||||
| for device in $devices; do | ||||
| 
 | ||||
|     # Get the device info using bluetoothctl | ||||
|     info=$(bluetoothctl info "$device") | ||||
| 
 | ||||
|     # Extract the name and battery percentage from the device info | ||||
|     name[i]=$(echo "$info" | awk '/Name:/ {for(i=2; i<=NF; i++) printf "%s ", $i;}') | ||||
|     battery[i]=$(echo "$info" | awk '/Battery Percentage:/ {print $4}' | tr -d '()') | ||||
| 
 | ||||
|      | ||||
| 
 | ||||
|     ((i=i+1)) | ||||
| done | ||||
| 
 | ||||
| echo '{"name":"'"${name[0]}"'","battery":"'"${battery[0]}"'"}' | ||||
							
								
								
									
										10
									
								
								eww/scripts/brightness.sh
									
										
									
									
									
										Executable file
									
								
							
							
						
						|  | @ -0,0 +1,10 @@ | |||
| #!/usr/bin/env bash | ||||
| 
 | ||||
| FILE_TO_WATCH="/sys/class/backlight/intel_backlight/brightness"   # Replace with the actual file path | ||||
| 
 | ||||
| cat "$FILE_TO_WATCH" | ||||
| 
 | ||||
| while true; do | ||||
|     inotifywait -e modify "$FILE_TO_WATCH" | ||||
|     cat "$FILE_TO_WATCH" | ||||
| done | ||||
							
								
								
									
										
											BIN
										
									
								
								eww/scripts/client
									
										
									
									
									
										Executable file
									
								
							
							
						
						
							
								
								
									
										8
									
								
								eww/scripts/media.sh
									
										
									
									
									
										Executable file
									
								
							
							
						
						|  | @ -0,0 +1,8 @@ | |||
| #!/usr/bin/env bash | ||||
| 
 | ||||
| status=$(playerctl status) | ||||
| title=$(playerctl metadata title) | ||||
| artist=$(playerctl metadata artist) | ||||
| album=$(playerctl metadata album) | ||||
| 
 | ||||
| echo '{"status":"'"$status"'","title":"'"$title"'","artist":"'"$artist"'","album":"'"$album"'"}' | ||||
							
								
								
									
										43
									
								
								eww/scripts/network.sh
									
										
									
									
									
										Executable file
									
								
							
							
						
						|  | @ -0,0 +1,43 @@ | |||
| #!/usr/bin/env bash | ||||
| 
 | ||||
| ethernet() { | ||||
| 	name="Wired" | ||||
| 	image="ethernet" | ||||
| } | ||||
| 
 | ||||
| wifi() { | ||||
| 	wifiInfo=$(nmcli -t -f active,ssid,signal device wifi list) | ||||
| 
 | ||||
| 	signalStrength=$(awk -F: '/yes:/ {print $3}' <<< $wifiInfo) | ||||
| 	name=$(awk -F: '/yes:/ {print $2}' <<< $wifiInfo) | ||||
| 
 | ||||
| 	if [[ $signalStrength -ge 70 ]]; then | ||||
| 		image="wifiHigh" | ||||
| 	elif [[ $signalStrength -ge 60 ]]; then | ||||
| 		image="wifiMedium" | ||||
| 	elif [[ $signalStrength -ge 40 ]]; then | ||||
| 		image="wifiLow" | ||||
| 	else | ||||
| 		image="wifiVeryLow" | ||||
| 	fi | ||||
| } | ||||
| 
 | ||||
| while true; do | ||||
| 	name="No Connection" | ||||
| 	image="n.A." | ||||
| 
 | ||||
| 	networkInfo=$(nmcli -f NAME,TYPE connection show --active | awk '!/loopback/ && NR > 1') | ||||
| 
 | ||||
| 	if [[ $(awk '/wifi/' <<< "$networkInfo") ]]; then | ||||
| 		wifi | ||||
| 	fi | ||||
| 
 | ||||
| 	if [[ $(awk '/ethernet/' <<< "$networkInfo") ]]; then | ||||
| 		ethernet | ||||
| 	fi | ||||
| 
 | ||||
| 
 | ||||
| 	echo '{"name":"'"$name"'","image":"'"$image"'"}' | ||||
| 
 | ||||
| 	sleep 2 | ||||
| done | ||||
							
								
								
									
										24
									
								
								eww/scripts/volume.sh
									
										
									
									
									
										Executable file
									
								
							
							
						
						|  | @ -0,0 +1,24 @@ | |||
| #!/usr/bin/env bash | ||||
| 
 | ||||
| generate() { | ||||
|     message=$(wpctl get-volume @DEFAULT_AUDIO_SINK@) | ||||
|     volume=$(awk '{print $2 * 100}' <<< "$message") | ||||
| 
 | ||||
|     if [[ $(awk '{print $3}' <<< "$message") == "[MUTED]" ]]; then | ||||
|         muted=1 | ||||
|     else | ||||
|         muted=0 | ||||
|     fi | ||||
| 
 | ||||
|     echo '{"volume":"'"$volume"'","muted":"'"$muted"'"}' | ||||
| } | ||||
| 
 | ||||
| generate | ||||
| 
 | ||||
| pactl subscribe | while read -r event; do | ||||
|     if [[ "$event" == *"Event 'change'"* ]]; then | ||||
|          | ||||
|         generate | ||||
| 
 | ||||
|     fi | ||||
| done | ||||
|  | @ -1,25 +1,25 @@ | |||
| (deflisten brightnessValue | ||||
|     :initial "0" | ||||
|     `../ewwScripts/brightness.sh`) | ||||
|   :initial "0" | ||||
| `./scripts/brightness.sh`) | ||||
| 
 | ||||
| (deflisten network | ||||
|     :initial '{"name":"No Connection","image":"n.A."}' | ||||
|     `../ewwScripts/network.sh`) | ||||
|   :initial '{"name":"No Connection","image":"n.A."}' | ||||
| `./scripts/network.sh`) | ||||
| 
 | ||||
| (deflisten workspaces | ||||
|     :initial '' | ||||
|     `../ewwScripts/client`) | ||||
|   :initial '' | ||||
| `./scripts/client`) | ||||
| 
 | ||||
| (defpoll bluetooth | ||||
|     :initial '{"name":"","battery":"0"}' | ||||
|     :interval "2s" | ||||
|     `../ewwScripts/bluetooth.sh`) | ||||
|   :initial '{"name":"","battery":"0"}' | ||||
|   :interval "2s" | ||||
| `./scripts/bluetooth.sh`) | ||||
| 
 | ||||
| (deflisten volume | ||||
|     :initial '{"volume":"0","muted":"0"}' | ||||
|     `../ewwScripts/volume.sh`) | ||||
|   :initial '{"volume":"0","muted":"0"}' | ||||
| `./scripts/volume.sh`) | ||||
| 
 | ||||
| (defpoll media | ||||
|     :initial '{"status":"","name":""}' | ||||
|     :interval "2s" | ||||
|     `../ewwScripts/media.sh`) | ||||
|   :initial '{"status":"","name":""}' | ||||
|   :interval "2s" | ||||
| `./scripts/media.sh`) | ||||
|  |  | |||