Last active
October 1, 2025 10:03
-
-
Save iamevn/8045cfb1682249bd36b478008cbed7a8 to your computer and use it in GitHub Desktop.
disable pesky game mode popup using nix on macos
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { pkgs, ... }: | |
| let | |
| # disable game mode for mpv | |
| mpv-unwrapped = pkgs.mpv-unwrapped.overrideAttrs (attrs: { | |
| postPatch = (attrs.postPatch or "") + '' | |
| substituteInPlace TOOLS/osxbundle/mpv.app/Contents/Info.plist \ | |
| --replace-fail 'public.app-category.games' 'public.app-category.video' | |
| ''; | |
| }); | |
| mpv-no-game-mode = pkgs.mpv.override { | |
| mpv = mpv-unwrapped; | |
| }; | |
| in { | |
| # use mpv-no-game-mode wherever you would be specifying packages, e.g. | |
| packages = with pkgs; [ | |
| cowsay | |
| intercal | |
| mpv-no-game-mode | |
| sl | |
| toilet | |
| ]; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment