mirror of
https://github.com/markqvist/Reticulum.git
synced 2025-07-24 15:25:32 -04:00
Added path table output to rnpath utility
This commit is contained in:
parent
1be00a5c41
commit
6d23da360d
3 changed files with 83 additions and 38 deletions
|
@ -93,12 +93,15 @@ def host_os():
|
|||
from .vendor.platformutils import get_platform
|
||||
return get_platform()
|
||||
|
||||
def timestamp_str(time_s):
|
||||
timestamp = time.localtime(time_s)
|
||||
return time.strftime(logtimefmt, timestamp)
|
||||
|
||||
def log(msg, level=3, _override_destination = False):
|
||||
global _always_override_destination
|
||||
|
||||
if loglevel >= level:
|
||||
timestamp = time.time()
|
||||
logstring = "["+time.strftime(logtimefmt)+"] ["+loglevelname(level)+"] "+msg
|
||||
logstring = "["+timestamp_str(time.time())+"] ["+loglevelname(level)+"] "+msg
|
||||
logging_lock.acquire()
|
||||
|
||||
if (logdest == LOG_STDOUT or _always_override_destination or _override_destination):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue