Compare commits
2 Commits
6472c4ea2d
...
f8707672a0
Author | SHA1 | Date |
---|---|---|
simon | f8707672a0 | |
simon | 41c2b1c3bf |
18
README.md
18
README.md
|
@ -29,17 +29,17 @@ None standard Python dependencies:
|
|||
|
||||
## i3block_shell
|
||||
A bunch of simple bash scripts to be called via i3blocks.
|
||||
* **coretemp.sh** Echos average temperature of all CPU cores by parsing output of `sensors` from package *lm_sensors*
|
||||
* **date.sh**: Echos the current date
|
||||
* on left click: uses notify-send to print current three month calendar
|
||||
* **df.sh**: Echos current diskfree level of the root partition
|
||||
* on left click: uses notify-send to print the df of all relevant connected partitions
|
||||
* **ip.sh**: Echos current ip addresses in use or inactive when offline
|
||||
* **coretemp.sh**: Echos average temperature of all CPU cores by parsing output of `sensors` from package *lm_sensors*, uses icons from [fontawesome.com](https://fontawesome.com/).
|
||||
* **date.sh**: Echos the current date.
|
||||
* on left click: uses notify-send to print current three month calendar.
|
||||
* **df.sh**: Echos current diskfree level of the root partition.
|
||||
* on left click: uses notify-send to print the df of all relevant connected partitions.
|
||||
* **ip.sh**: Echos current ip addresses in use or inactive when offline.
|
||||
* **updates.sh**: Echos how many updates are pending.
|
||||
* on left click: echos the complete list of all pending updates
|
||||
* on right click: refreshes the current pending updates and echos result
|
||||
* on left click: echos the complete list of all pending updates.
|
||||
* on right click: refreshes the current pending updates and echos result.
|
||||
* **wifiinfo.sh**: Echos current db level of signal strength.
|
||||
* on left click: Uses nmcli to echo all device status
|
||||
* on left click: Uses nmcli to echo all device status.
|
||||
|
||||
|
||||
## weather_applet
|
||||
|
|
|
@ -31,13 +31,14 @@ def main():
|
|||
client.connect("localhost", 6600)
|
||||
except ConnectionRefusedError:
|
||||
# mpd is not connecting, try to start
|
||||
output = subprocess.run(["mpd"], capture_output=True)
|
||||
if output.returncode == 0:
|
||||
# connect
|
||||
client.connect("localhost", 6600)
|
||||
else:
|
||||
# that failed, all is lost
|
||||
return
|
||||
if mpc_command == 'toggle':
|
||||
output = subprocess.run(["mpd"], capture_output=True)
|
||||
if output.returncode == 0:
|
||||
# connect
|
||||
client.connect("localhost", 6600)
|
||||
else:
|
||||
# that failed, all is lost
|
||||
return
|
||||
# follow mpc_command
|
||||
if mpc_command == 'toggle':
|
||||
mpd_playback.toggle(client, signal_id)
|
||||
|
|
Loading…
Reference in New Issue