-
-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into docs-split-modules
- Loading branch information
Showing
10 changed files
with
191 additions
and
152 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
{ | ||
config, | ||
lib, | ||
pkgs, | ||
options, | ||
... | ||
}: | ||
let | ||
template = | ||
let | ||
inherit (config.lib.stylix) colors; | ||
inherit (config.stylix) fonts; | ||
in | ||
import ./template.nix { inherit colors fonts; }; | ||
in | ||
{ | ||
options.stylix.targets = | ||
let | ||
inherit (config.lib.stylix) mkEnableTarget; | ||
in | ||
{ | ||
vencord.enable = mkEnableTarget "Vencord" true; | ||
vesktop.enable = mkEnableTarget "Vesktop" true; | ||
nixcord.enable = mkEnableTarget "Nixcord" true; | ||
}; | ||
|
||
config = lib.mkIf config.stylix.enable ( | ||
lib.mkMerge [ | ||
(lib.mkIf config.stylix.targets.vencord.enable { | ||
xdg.configFile."Vencord/themes/stylix.theme.css".text = template; | ||
}) | ||
|
||
(lib.mkIf config.stylix.targets.vesktop.enable ( | ||
lib.mkMerge [ | ||
(lib.mkIf pkgs.stdenv.hostPlatform.isLinux { | ||
xdg.configFile."vesktop/themes/stylix.theme.css".text = template; | ||
}) | ||
|
||
(lib.mkIf pkgs.stdenv.hostPlatform.isDarwin { | ||
home.file."Library/Application Support/vesktop/themes/stylix.theme.css".text = | ||
template; | ||
}) | ||
] | ||
)) | ||
|
||
(lib.mkIf config.stylix.targets.nixcord.enable ( | ||
lib.optionalAttrs (builtins.hasAttr "nixcord" options.programs) { | ||
xdg.configFile = | ||
let | ||
inherit (config.programs) nixcord; | ||
in | ||
lib.mkMerge [ | ||
(lib.mkIf nixcord.discord.enable { | ||
"Vencord/themes/stylix.theme.css".text = template; | ||
}) | ||
|
||
(lib.mkIf nixcord.vesktop.enable { | ||
"vesktop/themes/stylix.theme.css".text = template; | ||
}) | ||
]; | ||
|
||
programs.nixcord.config.enabledThemes = [ "stylix.theme.css" ]; | ||
} | ||
)) | ||
] | ||
); | ||
} |
File renamed without changes.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
{ lib, pkgs, ... }: | ||
|
||
let | ||
package = pkgs.discord.override { | ||
withVencord = true; | ||
}; | ||
in | ||
{ | ||
stylix.testbed.application = { | ||
enable = true; | ||
name = "discord"; | ||
inherit package; | ||
}; | ||
|
||
environment.systemPackages = [ package ]; | ||
nixpkgs.config.allowUnfreePredicate = | ||
pkg: | ||
builtins.elem (lib.getName pkg) [ | ||
"discord" | ||
]; | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ pkgs, ... }: | ||
|
||
let | ||
package = pkgs.vesktop; | ||
in | ||
{ | ||
stylix.testbed.application = { | ||
enable = true; | ||
name = "vesktop"; | ||
inherit package; | ||
}; | ||
|
||
environment.systemPackages = [ package ]; | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains 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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains 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
Oops, something went wrong.