diff --git a/i3/i3csstatus.conf b/i3/i3csstatus.conf new file mode 100644 index 0000000000000000000000000000000000000000..2754972131a8055a3d3fd998653e7df873492922 --- /dev/null +++ b/i3/i3csstatus.conf @@ -0,0 +1,176 @@ +refresh = 1 + + +# [exec] +# program = python3 +# separator = 10 +# parser = i3 +# _color = blue +# stdin +# import time +# +# i = 0 +# while True: +# i += 1 +# print('[{"full_text":"PY<i>THON</i> '+str(i)+'", "short_text":"P", "color":"#00FFFF", "background":"red", "border":"blue", "border_top":3, "min_width":"AHOJ PYTHON", "align":"center", "urgent":true, "separator": false, "separator_block_width":30, "markup":"pango"}]', flush=True) +# time.sleep(3) + +# [osdd_last] +# type = _pipe +# path = $XDG_RUNTIME_DIR/osdd_to_i3csstatus + + +# [pipe] +# path = a +# show_old = 5 +# max_old = 10 +# no_data_handler + # [constant] + # text = AHOJ + +# [api_time] +# _type=http +# url = http://worldtimeapi.org/api/timezone/Europe/Prague +# period = 30 +# max_old = 20 +# show_old = 10 + + +[osdd_last] +_type = file +path = ~/.osdd_last +_exec = terminal -e bash -i -c "tail -n500 ~/.osdd_log;read" + +[offlineimap_status] +_type = file +path = ~/.offlineimap.log + +[checkmail_status] +_type = file +path = ~/.cm +_exec = i3-workspace goto-workspace --workspace MAIL + +[wireless_channel] +_type = exec +parser = i3 +program = python3 +arguments = -u +delay = 1 +separator = 10 +stdin + import sys + import time + import subprocess + i = 0 + while True: + try: + process = subprocess.Popen(["iwlist", "wlp1s0", "channel"], stdout=subprocess.PIPE) + ch = int(process.communicate()[0].decode().split("\n")[-3].split()[4][:-1]) + print(f'[{{"full_text":"{ch}"}}]', flush=True) + except Exception as e: + print(e, file=sys.stderr) + print("[]", flush=True) + time.sleep(10); + + +[wireless] +_type=i3status +name = wireless _first_ +config<<AMEN +format_up = "W: (%quality %essid) %ip" +format_down = "W: down" +AMEN +_exec = terminal -e nmtui + +[ethernet] +_type=i3status +name=ethernet _first_ +config = + format_up = "E: %ip (%speed)" + format_down = "E: down" +global_cache = 1 + +# [battery_i3] +# _type = i3status +# name = battery all +# config = + # format = "%status %percentage %remaining %consumption" + +[battery] +_exec = terminal -e battop + +[load] +_type = i3status +config = format = "%1min L" +_exec = terminal -e htop + +[memory] +_type = i3status +config = + format = "%available" + threshold_degraded = "1G" + format_degraded = "MEMORY %available" + +[time] +format = yyyy-MM-dd HH:mm:ss +refresh +_exec = terminal -e calcurse + + +# [ICE_speed] +# _type=http +# url = https://iceportal.de/api1/rs/status +# period = 5 +# show_old = 20 +# max_old = 120 +# error_handler = +# no_data_handler = +# _exec = chromium https://iceportal.de/ + +# [ICE_next_stop] +# _type=http +# url = https://iceportal.de/api1/rs/tripInfo/trip +# error_handler = +# period = 20 +# show_old = 60 +# max_old = 300 +# _exec = chromium https://iceportal.de/ + +[CD_speed] +_type=http +url = http://cdwifi.cz/portal/api/vehicle/realtime +period = 5 +show_old = 20 +max_old = 120 +error_handler = +no_data_handler = +_exec = chromium http://cdwifi.cz + +[CD_next_stop] +_type=http_multi +urls = http://cdwifi.cz/portal/api/timetable/connexion/current?locale=cs_CZ + http://cdwifi.cz/portal/api/vehicle/realtime +error_handler = +period = 20 +show_old = 60 +max_old = 300 +_exec = chromium http://cdwifi.cz + +# [OBB_speed] +# _type=http +# url = https://railnet.oebb.at/api/speed +# period = 5 +# show_old = 20 +# max_old = 120 +# error_handler = +# no_data_handler = +# _exec = chromium http://railnet.oebb.at/ + +# [OBB_next_stop] +# _type=http +# url = https://railnet.oebb.at/assets/modules/fis/combined.json +# error_handler = +# period = 20 +# show_old = 60 +# max_old = 300 +# _exec = chromium http://railnet.oebb.at/