mirror of
https://github.com/SteamDeckHomebrew/decky-loader.git
synced 2026-06-13 12:15:09 +03:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 6ff704512c | |||
| d31c2bf034 | |||
| b7a884f26f | |||
| a477bf6829 | |||
| 1e8bf43e5f |
@@ -23,7 +23,7 @@
|
||||
[Become a backer or sponsor](https://opencollective.com/steamdeckhomebrew) to support our work! Contributing to our collective effort will help Decky Loader developers cover the costs of web servers, acquire new development hardware, and more.
|
||||
|
||||
<!-- SPONSORS COMMENTED OUT UNTIL WE GET SOME SPONSORS TO AVOID BLANK SVG SPACE -->
|
||||
<!-- <a href="https://opencollective.com/steamdeckhomebrew"><img alt="Steam Deck Homebrew sponsors on Open Collective" src="https://opencollective.com/steamdeckhomebrew/sponsors.svg?button=true&avatarHeight=46&width=750"></a> -->
|
||||
<a href="https://opencollective.com/steamdeckhomebrew"><img alt="Steam Deck Homebrew sponsors on Open Collective" src="https://opencollective.com/steamdeckhomebrew/sponsors.svg?button=true&avatarHeight=46&width=750"></a>
|
||||
|
||||
<a href="https://opencollective.com/steamdeckhomebrew"><img alt="Steam Deck Homebrew backers on Open Collective" src="https://opencollective.com/steamdeckhomebrew/backers.svg?button=false&avatarHeight=46&width=750"></a>
|
||||
|
||||
|
||||
@@ -116,28 +116,26 @@ def get_username() -> str:
|
||||
return _get_user()
|
||||
|
||||
def setgid(user : UserType = UserType.HOST_USER):
|
||||
user_id = 0
|
||||
|
||||
if user == UserType.HOST_USER:
|
||||
user_id = _get_user_group_id()
|
||||
host_user_group_id, effective_user_group_id = _get_user_group_id(), _get_effective_user_group_id()
|
||||
if host_user_group_id == effective_user_group_id:
|
||||
pass
|
||||
elif user == UserType.HOST_USER:
|
||||
os.setgid(host_user_group_id)
|
||||
elif user == UserType.EFFECTIVE_USER:
|
||||
pass # we already are
|
||||
os.setgid(effective_user_group_id)
|
||||
else:
|
||||
raise Exception("Unknown user type")
|
||||
|
||||
os.setgid(user_id)
|
||||
|
||||
def setuid(user : UserType = UserType.HOST_USER):
|
||||
user_id = 0
|
||||
|
||||
if user == UserType.HOST_USER:
|
||||
user_id = _get_user_id()
|
||||
host_user_id, effective_user_id = _get_user_id(), _get_effective_user_id()
|
||||
if host_user_id == effective_user_id:
|
||||
pass
|
||||
elif user == UserType.HOST_USER:
|
||||
os.setuid(host_user_id)
|
||||
elif user == UserType.EFFECTIVE_USER:
|
||||
pass # we already are
|
||||
os.setuid(effective_user_id)
|
||||
else:
|
||||
raise Exception("Unknown user type")
|
||||
|
||||
os.setuid(user_id)
|
||||
|
||||
async def service_active(service_name : str) -> bool:
|
||||
res, _, _ = await run(["systemctl", "is-active", service_name], stdout=DEVNULL, stderr=DEVNULL)
|
||||
|
||||
@@ -56,7 +56,8 @@ const PluginView: FC = () => {
|
||||
<PanelSectionRow key={name}>
|
||||
<ButtonItem layout="below" onClick={() => setActivePlugin(name)}>
|
||||
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between' }}>
|
||||
{icon}
|
||||
{/* @ts-expect-error - ErrorBoundary is given fallback in the patch in errorboundary-hook.tsx, but it's not typed */}
|
||||
<ErrorBoundary fallback={<span>❌</span>}>{icon}</ErrorBoundary>
|
||||
<div>{name}</div>
|
||||
<NotificationBadge show={updates?.has(name)} style={{ top: '-5px', right: '-5px' }} />
|
||||
</div>
|
||||
|
||||
@@ -80,7 +80,7 @@ export default function TestingVersionList() {
|
||||
<ul style={{ listStyleType: 'none', padding: '0' }}>
|
||||
{testingVersions.map((version) => {
|
||||
return (
|
||||
<li>
|
||||
<li key={`${version.id}_${version.name}`}>
|
||||
<Field
|
||||
label={
|
||||
<>
|
||||
|
||||
@@ -240,6 +240,7 @@ const BrowseTab: FC<{ setPluginCount: Dispatch<SetStateAction<number | null>> }>
|
||||
})
|
||||
.map((plugin: StorePlugin) => (
|
||||
<PluginCard
|
||||
key={`${plugin.id}_${plugin.name}`}
|
||||
storePlugin={plugin}
|
||||
installedPlugin={installedPlugins.find((installedPlugin) => installedPlugin.name === plugin.name)}
|
||||
/>
|
||||
|
||||
@@ -81,6 +81,7 @@ class Toaster extends Logger {
|
||||
const info = {
|
||||
showToast: toast.showToast,
|
||||
sound: toast.sound,
|
||||
playSound: toast.playSound,
|
||||
eFeature: 0,
|
||||
toastDurationMS: toastData.nToastDurationMS,
|
||||
bCritical: toast.critical,
|
||||
|
||||
Reference in New Issue
Block a user