rin/packages: use multitask and media key patch on discord-plugged

This commit is contained in:
LavaDesu 2021-12-18 20:33:30 +07:00
parent 7da808dafd
commit 2f3bcd4b10
Signed by: cilly
GPG key ID: 6500251E087653C9
4 changed files with 45 additions and 0 deletions

View file

@ -1,11 +1,24 @@
{ config, enableGUI, inputs, pkgs, ... }:
let
mediaKeyPatch = pkgs.fetchurl {
url = "https://github.com/powercord-org/powercord/commit/6c9e57de7fcbd50e473c6d9b1c81e56fef85fa93.diff";
sha256 = "16jy1qkkbjxmylqpjfm3y47nf40hw5anq284aj6kc9z3n3323pic";
};
discord = pkgs.discord-plugged.override {
powercord = pkgs.powercord.override {
powercord-unwrapped = pkgs.powercord.unwrapped.overrideAttrs(old: {
patches = (if (old ? patches) then old.patches else []) ++ [
mediaKeyPatch
./powercordMediaKeyPatchPatch.patch
];
});
};
plugins = [
inputs.better-status-indicators
inputs.channel-typing
inputs.discord-tweaks
inputs.fix-user-popouts
inputs.multitask
inputs.no-double-back-pc
inputs.powercord-popout-fix
inputs.rolecolor-everywhere

View file

@ -0,0 +1,14 @@
diff --git a/src/patcher.js b/src/patcher.js
index d1609554029..780740d7423 100644
--- a/src/patcher.js
+++ b/src/patcher.js
@@ -22,7 +22,8 @@ console.log('Hello from Powercord!');
let disableMediaHandling = false;
try {
- settings = require(join(__dirname, '../settings/pc-general.json'));
+ const { SETTINGS_FOLDER } = require('./fake_node_modules/powercord/constants');
+ settings = require(join(SETTINGS_FOLDER, 'pc-general.json'));
disableMediaHandling = settings.disableMediaHandling;
} catch (e) {}