We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see ourdocumentation.
There was an error while loading.Please reload this page.
1 parent175801a commit98b5550Copy full SHA for 98b5550
src/ashpk_core.py
@@ -1313,13 +1313,15 @@ def yes_no(msg):
1313
defmain():
1314
# TODO 2023 exception: Make 'ash tree' run without root permissions
1315
ifsys.platform.startswith("linux")andos.geteuid()!=0:
1316
-exit("sudo/doas is required to run ash!")
+exit("F: Run ash with super user privileges!")
1317
+elifsys.platform.startswith("cosmo")andos.getuid()!=0:### TODO use geteuid when fixed
1318
1319
elifsys.platform.startswith("windows"):
-print("TODO")
1320
+fromctypesimportwindll# type: ignore
1321
+ifwindll.shell32.IsUserAnAdmin()!=0:
1322
+exit("F: Run ash with admin privileges!")
1323
elifsys.platform.startswith("darwin"):
1324
print("TODO")
-elifsys.platform.startswith("cosmo"):
1325
else:
1326
importer=DictImporter()# Dict importer
1327
# isChroot = chroot_check() ### TODO