6,7 → 6,7 |
|
from lib.network import download |
from lib.logging import log |
from lib.constants import tools_cache, tools_cache_kolibri_img |
from lib.constants import tools, tools_workspace, tools_cache, tools_cache_kolibri_img |
|
def generate_script_executing_script(script_to_execute): |
script_to_execute = script_to_execute.replace("\\", "\\\\") |
25,9 → 25,8 |
log("Done") |
|
if __name__ == "__main__": |
tools_get_started_py = os.path.abspath(__file__) |
tools = os.sep.join(tools_get_started_py.split(os.sep)[:-1]) |
tools_workspace = os.sep.join([tools, "workspace"]) |
# Create _tools/cache folder if not exist |
os.makedirs(tools_cache, exist_ok = True) |
# Create (in current directory) scripts that execute |
# the same named scripts from _tools/workspace |
tools_workspace_run_py = os.path.join(tools_workspace, "run.py") |
38,6 → 37,5 |
# TODO: Do anything if tup doesn't exist |
os.system("tup init") |
# Download IMG to _tools/cache |
os.makedirs(tools_cache, exist_ok = True) |
img_url = "http://builds.kolibrios.org/eng/data/data/kolibri.img" |
download(img_url, tools_cache_kolibri_img, skip_exist = True) |