-
Notifications
You must be signed in to change notification settings - Fork 203
New utility: gamemodelist #346
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New utility: gamemodelist #346
Conversation
752bb95
to
b563d36
Compare
Here's an example of my running the command after starting a game.
Started steam game with pgrep -f RustClient.exe | xargs -n1 -- sudo -- renice -n -1 |
b563d36
to
18989a0
Compare
18989a0
to
605cd4d
Compare
I like it 👍 Unfortunately though |
@mdiluz how would one query |
So getting that set up would be way more involved unfortunately. The current API has a query function here that can get the status for a single PID, but for your use case what you'd possibly need is a new API method to fetch the list of currently registered processes. |
While it may not be a complete solution it does its intended purpose. Most games would launch from Steam via I think while no API exists this is a good enough stop-gap measure for users trying to troubleshoot if the game they've opened is running with gamemode successfully. I had trouble verifying this before writing the script. With the lack of API in |
You make a good point and you make it well 👍 We'll have to see if the Feral folks decide whether it's fair to merge with the current "bug", but I think it seems sane, and this feels like a little block of work I'd be happy to PR some time in the next few weeks when I get a chance. |
While trying out gamemode on Ubuntu 18.04 I had trouble figuring out whether or not my games were running with gamemode enabled. I wrote this utility which prints all processes loaded with the gamemode shared library. - [x] Added utility to `data/` folder. - [x] Update meson installer. - [x] Included section 1 manual. - [x] Updated README for Ubuntu 18.04 build instructions. Steam supports Ubuntu 18.04. I'm open to feedback and generally this should work for any distrobution since it makes use of the Linux `/proc` filesystem. [Learn more about `/proc`][1]. [1]: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/tree/Documentation/filesystems/proc.rst?h=v5.15.12
605cd4d
to
150ebd6
Compare
Rebased on master. |
This looks very useful - thank you! My only suggestion would be to briefly mention in the manpage and comments that this is currently limited to games that request gamemode via |
I'll push a change. Also, the CI failure appears to be unrelated to my change. Does the CI failure block merging? |
@afayaz-feral I pushed a new commit instead of squashing like I normally do so that you can see what changed. |
I wasn't able to replicate check-format.sh issues reported. Test imageFROM ubuntu:20.04
ENV DEBIAN_FRONTEND=noninteractive
RUN set -ex; \
apt-get update; \
apt-get install -y build-essential meson appstream clang clang-format clang-tools libdbus-1-dev libinih-dev libsystemd-dev git
RUN set -ex; \
yes | adduser ci-user
USER ci-user Run docker as user
Build image
Run CI checks
|
I figured it out. I'll open a separate PR. |
#355 opened separate pull request to fix CI checks. |
Thanks, I will merge this now.
I couldn't replicate this locally either, and hadn't gotten around to looking into it in more depth. So thank you for solving it! |
You're welcome. |
Might seem obvious, but for sake of completeness, it is worth mentioning that running That said, nice script! :-) |
While trying out gamemode on Ubuntu 18.04 I had trouble figuring out whether or not my games were running with gamemode enabled. I wrote this utility which prints all processes loaded with the gamemode shared library.
data/
folder.I'm open to feedback and generally this should work for any distribution since it makes use of the Linux
/proc
filesystem. Learn more about/proc
.Thanks in advance