mirror of
https://github.com/SteamDeckHomebrew/decky-loader.git
synced 2026-06-17 00:37:49 +00:00
Fix for wrong path for settings json files (#258)
Co-authored-by: AAGaming <aa@mail.catvibers.me>
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import grp
|
||||
import pwd
|
||||
import re
|
||||
import ssl
|
||||
import subprocess
|
||||
@@ -56,6 +58,14 @@ def get_user() -> str:
|
||||
raise ValueError("helpers.get_user method called before user variable was set. Run helpers.set_user first.")
|
||||
return user
|
||||
|
||||
#Get the user owner of the given file path.
|
||||
def get_user_owner(file_path) -> str:
|
||||
return pwd.getpwuid(os.stat(file_path).st_uid)[0]
|
||||
|
||||
#Get the user group of the given file path.
|
||||
def get_user_group(file_path) -> str:
|
||||
return grp.getgrgid(os.stat(file_path).st_gid)[0]
|
||||
|
||||
# Set the global user group. get_user must be called first
|
||||
def set_user_group() -> str:
|
||||
global group
|
||||
|
||||
Reference in New Issue
Block a user