Import flake.nix file into another flake.nix file

There’s a bunch of weird stuff going on in this repo, so maybe think twice before copying things you find here–I was just kind of messing around. But yes you can import a flake into another flake, I do so here: https://github.com/MatrixManAtYrService/sieve-illwill/blob/main/flake.nix#L30.

Keep in mind that a flake is a function, so you have to both import it and call it.

      zippy-flake = import ./subflake/zippy/flake.nix;
      zippy-outputs = zippy-flake.outputs {
        inherit self;
        inherit nixpkgs;
        inherit flake-utils;
      };
      zippy = zippy-outputs.packages.${system}.default;

As for modifying an attribute on one of the outputs, I’m not sure off the top of my head: Nix attributes are immutable, but there ought to be a way to create a new attribute which has the desired mutation (overlays come to mind, but I’m not confident about that).