gamemode.rules.in 542 B

1234567891011121314
  1. /*
  2. * Allow users in privileged gamemode group to run cpugovctl &
  3. * gpuclockctl without authentication
  4. */
  5. polkit.addRule(function (action, subject) {
  6. if ((action.id == "com.feralinteractive.GameMode.governor-helper" ||
  7. action.id == "com.feralinteractive.GameMode.gpu-helper" ||
  8. action.id == "com.feralinteractive.GameMode.cpu-helper" ||
  9. action.id == "com.feralinteractive.GameMode.procsys-helper") &&
  10. subject.isInGroup("@GAMEMODE_PRIVILEGED_GROUP@"))
  11. {
  12. return polkit.Result.YES;
  13. }
  14. });