setup.sh and installing on new system

This commit is contained in:
Karol Krzosa
2026-06-17 22:13:50 +02:00
parent 466220c7aa
commit bd9506a9be
5 changed files with 95 additions and 58 deletions

View File

@@ -1,7 +1,6 @@
#!/usr/bin/python3
import os, subprocess, json
def readfile(path):
fd = open(path, "r")
result = fd.read()
@@ -34,7 +33,7 @@ for appdir in appsdir:
_exec = line[5:]
elif line.startswith("Type="):
_type = line[5:]
elif line.startswith("Name="):
elif line.startswith("Name=") and _name is None:
_name = line[5:]
elif line.startswith("NoDisplay="):
_nodisplay = line[10:]
@@ -49,6 +48,7 @@ for appdir in appsdir:
if _nodisplay == "true" or _hidden == "true":
continue
vals[_name] = {"kind": "app", "exec": _exec, "path": path}
@@ -94,7 +94,6 @@ if result.returncode != 0:
choice = result.stdout.strip()
val = vals[choice]
if val["kind"] == "bin":
subprocess.run([val["path"]])
elif val["kind"] == "app":