Exemplo n.º 1
0
import tilda

tilda.main("rotary_phone/main.py")

Exemplo n.º 2
0
def file(file, remove):
    try:
        a = None
        with open(file, 'r') as f:
            a = f.read().strip()
        if remove:
            os.remove(file)
        return app(a)
    except Exception as e:
        print("Not found: %s" % file)

def any_home():
    h = [a for a in root if a.startswith("home")]
    return h[0] if len(h) else False

if "no_boot" in root:
    print("no_boot found, aborting boot sequence")
elif "bootstrap.py" in root:
    print("Bootstrapping...")
    tilda.main("bootstrap.py")
else:
    start = None
    if "main.py" in root:
        start = "main.py"
    start = start or file("once.txt", True) or file("default_app.txt", False) or any_home()
    if ".py" not in start:
        start += "/main.py"
    print("Booting into %s" % start)
    tilda.main(start)

Exemplo n.º 3
0
def file(file, remove):
    try:
        a = None
        with open(file, 'r') as f:
            a = f.read().strip()
        if remove:
            os.remove(file)
        return app(a)
    except Exception as e:
        print("Not found: %s" % file)


def any_home():
    h = [a for a in root if a.startswith("home")]
    return h[0] if len(h) else False


if "no_boot" in root:
    print("no_boot found, aborting boot sequence")
else:
    start = None
    if "main.py" in root:
        start = "main.py"
    start = start or file("once.txt", True) or file(
        "default_app.txt", False) or any_home() or "bootstrap.py"
    if ".py" not in start:
        start += "/main.py"
    print("Booting into %s" % start)
    tilda.main(start)
Exemplo n.º 4
0
### Author: Paul Brook
### Description: Chuckie Egg
### Category: Games
### License: GPLv3
### reboot-before-run: true
### Appname: Chuckie Egg

import tilda

tilda.main()