add scripts and config

This commit is contained in:
2023-07-12 17:02:27 +07:00
parent 520fb7cd75
commit 4b1d0cd562
12 changed files with 365 additions and 0 deletions
+21
View File
@@ -0,0 +1,21 @@
#!/usr/bin/env python
import json
import os
import subprocess
tmp = os.popen("lutris -ojl").read()
games = json.loads(tmp)
gameslist = ""
concat = ""
for item in games:
gameslist = gameslist + concat + item["name"]
concat = "\n"
tmp = subprocess.getoutput("echo \"" + gameslist + "\" | wofi -n -d -p \"Select Game:\"")
for item in games:
if item["name"] == tmp:
subprocess.Popen(["lutris","lutris:rungameid/" + str(item["id"])])
break