kopia lustrzana https://github.com/micropython/micropython-lib
Merge 72cf415ad7
into 567540d4e0
commit
b5dc302eac
|
@ -39,6 +39,12 @@ def exists(fname):
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
||||||
|
def validate_boot_file():
|
||||||
|
if not exists(RC):
|
||||||
|
with open(RC, "w") as f:
|
||||||
|
f.write("# boot.py -- run on boot-up\n")
|
||||||
|
|
||||||
|
|
||||||
def get_daemon_status():
|
def get_daemon_status():
|
||||||
with open(RC) as f:
|
with open(RC) as f:
|
||||||
for l in f:
|
for l in f:
|
||||||
|
@ -71,6 +77,7 @@ def change_daemon(action):
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
validate_boot_file()
|
||||||
status = get_daemon_status()
|
status = get_daemon_status()
|
||||||
|
|
||||||
print("WebREPL daemon auto-start status:", "enabled" if status else "disabled")
|
print("WebREPL daemon auto-start status:", "enabled" if status else "disabled")
|
||||||
|
|
Ładowanie…
Reference in New Issue