mirror of
https://github.com/FAUSheppy/config
synced 2025-12-06 15:11:35 +01:00
Changed behaviour for login tracking
This commit is contained in:
@@ -11,6 +11,7 @@ hc emit_hook reload
|
|||||||
xsetroot -solid '#5A8E3A'
|
xsetroot -solid '#5A8E3A'
|
||||||
|
|
||||||
# reset
|
# reset
|
||||||
|
rm ~/.config/herbstluftwm/*.log
|
||||||
hc keyunbind --all
|
hc keyunbind --all
|
||||||
pkill xautolock
|
pkill xautolock
|
||||||
# WONT WORK --> cause process has other name no idea which though pkill -s 15 hl_status_deamon #send SIGTERM for correct termination during write
|
# WONT WORK --> cause process has other name no idea which though pkill -s 15 hl_status_deamon #send SIGTERM for correct termination during write
|
||||||
|
|||||||
@@ -14,6 +14,6 @@ BATTERY_LOG = "battery.log"
|
|||||||
IP_LOG = "ip.log"
|
IP_LOG = "ip.log"
|
||||||
LOGINS_LOG = "logins.log"
|
LOGINS_LOG = "logins.log"
|
||||||
|
|
||||||
BATTERY_CRITICAL = 2 # in %
|
BATTERY_CRITICAL = 3 # in %
|
||||||
BAT_WARNING_STR = ">>>>>>>>>>>>>>>> ------------ WARNING BATTER FAILURE IMMINENT ------------ <<<<<<<<<<<<<"
|
BAT_WARNING_STR = ">>>>>>>>>>>>>>>> ------------ WARNING BATTER FAILURE IMMINENT ------------ <<<<<<<<<<<<<"
|
||||||
VALUES_KEPT = 10
|
VALUES_KEPT = 10
|
||||||
|
|||||||
@@ -47,8 +47,11 @@ def date():
|
|||||||
return hl_utils.shexec("date +' ^fg(#efefef)%H:%M^fg(#909090), %Y-%m-^fg(#efefef)%d'")
|
return hl_utils.shexec("date +' ^fg(#efefef)%H:%M^fg(#909090), %Y-%m-^fg(#efefef)%d'")
|
||||||
|
|
||||||
def logins():
|
def logins():
|
||||||
|
try:
|
||||||
with open(hl_utils.hlpath(LOGINS_LOG),'r') as f:
|
with open(hl_utils.hlpath(LOGINS_LOG),'r') as f:
|
||||||
return f.read()
|
return f.read()
|
||||||
|
except:
|
||||||
|
return ""
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
print(logins(),ip(),vpn(),guthaben(),battery(),date(),sep='',end='')
|
print(logins(),ip(),vpn(),guthaben(),battery(),date(),sep='',end='')
|
||||||
|
|||||||
Reference in New Issue
Block a user