-
Notifications
You must be signed in to change notification settings - Fork 0
/
i3pyLeft.py
61 lines (47 loc) · 1.17 KB
/
i3pyLeft.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# -*- coding: utf-8 -*-
import subprocess
from i3pystatus import Status
status = Status(standalone=True)
# Date and Clock without seconds display
status.register("clock",
format="%a %-d %b %H:%M",)
# determine spin state of hard disks, main system is on SSD
status.register("shell",
command="~/dotfiles/getHDDstate.sh sdb",
color="#ffffff",
error_color="#00ff00",
)
status.register("shell",
command="~/dotfiles/getHDDstate.sh sda",
color="#ffffff",
error_color="#00ff00",
)
# Shows the average load of the last minute and the last 5 minutes
# (the default value for format is used)
status.register("load")
# CPU temperature
status.register("temp",
format="Ç {temp:.0f}°C",)
status.register("cpu_usage",
format="Ñ {usage:3}%",
)
# Disk usage of /
status.register("disk",
path="/",
format="Ð {avail}G",)
status.register("mem",
format="{used_mem:.0f}/{total_mem:.0f} MiB",
)
# Pulseaudio volume
status.register("pulseaudio",
format="í {volume}%",)
# mpd status
status.register("mpd",
format="à {artist} - {title}",
# status={
# "pause": "▷",
# "play": "▶",
# "stop": "◾",
# },
)
status.run()