maralorn / nix-output-monitor

Pipe your nix-build output through the nix-output-monitor a.k.a nom to get additional information while building.
GNU Affero General Public License v3.0
835 stars 24 forks source link

Nix.Derivation: vendor parser #127

Closed ConnorBaker closed 7 months ago

ConnorBaker commented 7 months ago

This PR vendors the parser component of https://github.com/Gabriella439/Haskell-Nix-Derivation-Library (specifically Sorki's fork with the changes in https://github.com/Gabriella439/Haskell-Nix-Derivation-Library/pull/24) in an attempt to close #122.

[!Important]

The code being vendored is licensed under BSD3, while this project is licensed under GPL3. I am not a lawyer and have no idea how to, or if it is even possible to, dual-license them.

As is likely apparent from my appeal to a higher power in the code

let
  storePath = case path of
    Nix.ContentAddressedDerivationOutput{} -> error "God help us all it's a content-addressed output"
    _ -> path.path
in

I don't know the best way to handle such a case. Perhaps just fail and don't print the output?

ConnorBaker commented 7 months ago

Closed as not the right way to go about this: https://github.com/maralorn/nix-output-monitor/issues/122#issuecomment-1910294472