Skip to content

Commit 5dc04c4

Browse files
committed
Install GS
1 parent e32ef31 commit 5dc04c4

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

src/main.py

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,34 @@
55
from windows.launcher import Launcher
66
from webview import start
77

8-
def main():
8+
from sys import argv
9+
10+
def setup() -> tuple[AppData, Updater]:
911
app_data: AppData = AppData()
1012
updater: Updater = Updater(app_data)
13+
14+
return app_data, updater
15+
16+
def install() -> None:
17+
app_data, updater = setup()
1118

19+
for repo in app_data.repos:
20+
updater.update(repo)
21+
22+
updater.build_mac()
23+
24+
def main():
25+
app_data, updater = setup()
1226
launcher_path: str = app_data.v_path("launcher")
1327
port, _ = host(launcher_path)
1428

1529
Launcher(f"http://localhost:{port}/", app_data, updater)
1630
start()
1731

1832
if __name__ == '__main__':
33+
if "setup" in argv:
34+
install()
35+
exit(0)
36+
1937
main()
2038

0 commit comments

Comments
 (0)