dotfiles/modules/fonts.nix

19 lines
521 B
Nix
Raw Normal View History

2025-09-09 18:03:42 +02:00
{ pkgs, ... }:
2025-09-09 22:51:18 +02:00
let
2025-09-09 22:57:24 +02:00
# Fetch the JSON file and read its content
2025-09-09 22:51:18 +02:00
fontsJson = builtins.fetchurl {
url = "https://raw.githubusercontent.com/NixOS/nixpkgs/nixos-unstable/pkgs/data/fonts/nerd-fonts/manifests/fonts.json";
sha256 = "1kdmk4ayckixxckxbik9jg4fdqqgm7s5x1lvzd95v1g09bhn33wg";
};
# Parse the JSON and extract package names
2025-09-09 22:57:24 +02:00
fonts = builtins.fromJSON (builtins.readFile fontsJson);
2025-09-09 22:51:18 +02:00
packageNames = map (font: font.package) fonts;
in
2025-09-09 18:03:42 +02:00
{
2025-09-09 23:43:59 +02:00
fonts.packages = with pkgs; [
iosevka
comic-mono
];
2025-09-09 18:03:42 +02:00
}