nixcord
nixcord copied to clipboard
Support equicord
Love the program, was doing this manually with settings.json files and it was a nightmare.
Is there any chance in the future it could support equicord? Basically just vencord with extra plugins, even if only to add the extra plugins from their repo. I managed to get most of the ones I wanted with userPlugins but a few errored and I didn't feel like forking the plugins to make it work.
https://github.com/Equicord/Equicord
This should be possible, although just through filling in the extra config fields. I think making nix options for all of their new plugins should be on a different branch maybe if someone wants to try to do that, but it would be a pretty immense amount of work.
I managed to get most of the ones I wanted with userPlugins but a few errored and I didn't feel like forking the plugins to make it work.
How? I've tried using subdirectories on the Equicord repo and Nix complains at me:
userPlugins = {
anammox = "github:Equicord/Equicord/bfb97040b9e939d705778461c1857ccb36883d72?dir=src/equicordplugins/anammox";
};
error: A definition for option `home-manager.users.tohmais.programs.nixcord.userPlugins.anammox' is not of type `(path in the Nix store or package convertible to it) or string matching the pattern github:([[:alnum:].-]+)/([[:alnum:]/-]+)/([0-9a-f]{40}) convertible to it'. Definition values:
- In `/nix/store/f84i2nqc39yw5lrpih07lj6yi6axwm8n-source/modules/home-manager': "github:Equicord/Equicord/bfb97040b9e939d705778461c1857ccb36883d72?dir=src/equicordplugins/anammox"
I know why the above is erroring, but I was just wondering how you bypassed it.
This was my solution, it fetches the repo as a variable first
programs.nixcord =
let
equicordRepo = builtins.fetchGit {
url = "https://github.com/Equicord/Equicord.git";
rev = "8ce8d10fb41b19fb3986e978dc20fdf0697c14f1";
};
in
{
enable = true;
userPlugins = {
betterQuickReact = "${equicordRepo}/src/equicordplugins/betterQuickReact";
homeTyping = "${equicordRepo}/src/equicordplugins/homeTyping";
Thanks!
I've tried to use Equicord with Discord from the Nixpkgs. Seems like it's currently impossible: Vencord package and Equicord package have different structure. Here's Vencord structure:
And here's Equicord structure:
And Discord package wants patcher.js to be in the package root. Equibop works fine
Might be a recent-ish change? I've had trouble building with the workaround since updating my flake inputs a couple days ago. Temporarily disabled adding the extra equicord plugins for now.
Yeah, might be. I was trying to install some plugins, but had some dependency errors on every one
Yeah unfortunately mine have broken recently too, not sure why or now to get around it.
The most interesting part is he fact that those deps are present in the upstream (Vencord) So this issue is kinda strange to me
Same thing for vesktop -> equibop, would be great
This should be possible, although just through filling in the extra config fields. I think making nix options for all of their new plugins should be on a different branch maybe if someone wants to try to do that, but it would be a pretty immense amount of work.
Well it would be possible to split up the plugins by doing a plugins-equicord.nix file that adds the extra plugins on top when equicord is enabled.
im working on this at https://github.com/not-a-cowfr/equinix, right now i plan on just keeping it as a fork but i wouldnt be opposed to making a pr to this repo if thats what @KaylorBen wants
so far you can set it up just like normal nixcord and it works (though the icon doesnt seem to work but i also had that issue with nixcord so idk), but some config options are missing like plugins for example, so im working on a script to handle that, right now it looks like its correctly parsing everything into a json that shouldnt be to hard to then parse into nix
update: got some work on the json to nix parsing, im no nix pro but so far its not that bad one problem is for one that dont have any config options because theyre just enable/disable, however right now im not fetching the description for them. so far though the generated output seems to be valid(?) nix needs support for enums and sliders tho :P
update 2: added enum support, im going to sleep ive spent far too long on this
update 3: slider support (int value with a min/max limit)
who needs lib.types.bool
Oh wow, thanks a lot, @not-a-cowfr! I've actually thought about doing this myself in the past but abandoned the idea because Equicord has many more plugins, and it seemed like a big hassle to manually keep track of which plugins were added, removed, or had their settings changed.
I'll take a look later to try and understand what you did and see if I can contribute back as well!
When you feel confident with your changes, would you be open to creating a PR to merge them?
When you feel confident with your changes, would you be open to creating a PR to merge them?
yeah if i get the plugins script to a working state ill see how hard it would be to make into a pr instead of a separate thing