3 nixpkgs.url = "github:NixOS/nixpkgs/nixos-23.11";
4 pre-commit-hooks.inputs.nixpkgs.follows = "nixpkgs";
5 pre-commit-hooks.inputs.nixpkgs-stable.follows = "nixpkgs";
6 pre-commit-hooks.url = "github:cachix/pre-commit-hooks.nix";
11 inherit (inputs.nixpkgs) lib;
12 forAllSystems = f: lib.genAttrs lib.systems.flakeExposed (system: f rec {
14 pkgs = inputs.nixpkgs.legacyPackages.${system};
18 # nix -L build .#hello
19 packages = forAllSystems ({ pkgs, ... }: pkgs);
21 # nix -L develop or direnv allow
22 devShell = forAllSystems ({ pkgs, system, ... }:
33 (pkgs.texlive.combine {
34 inherit (pkgs.texlive)
36 collection-fontsrecommended
38 collection-latexrecommended
46 inherit (inputs.self.checks.${system}.pre-commit-check) shellHook;
47 FONTCONFIG_FILE = pkgs.makeFontsConf {
51 pkgs.gyre-fonts # TrueType substitutes for standard PostScript fonts
62 checks = forAllSystems (args: with args; {
63 pre-commit-check = inputs.pre-commit-hooks.lib.${system}.run {
66 nixpkgs-fmt.enable = true;