nix-narinfo-0.1.0.1: Parse and render .narinfo files

Safe HaskellSafe
LanguageHaskell2010

Nix.NarInfo

Contents

Synopsis

Builder

buildNarInfoWith :: Ord fp => (Bool -> fp -> Builder) -> (txt -> Builder) -> (hash -> Builder) -> NarInfo fp txt hash -> Builder Source #

Parser

parseNarInfoWith :: Ord fp => (Bool -> Parser fp) -> Parser txt -> Parser hash -> Parser (NarInfo fp txt hash) Source #

Types

data NarInfo fp txt hash Source #

Constructors

NarInfo 

Fields

  • storePath :: fp

    Absolute path of the derivation in nix store.

  • url :: txt

    Relative url (to current domain) to download nar file.

  • compression :: txt

    Name of the compression algorithm, eg. xz.

  • fileHash :: hash

    Hash of the compressed nar file. NOTE: to compute use "nix-hash --type sha256 --flat" (srk) this isn't fixed to sha256 but a prefix indicates the type e.g.: sha256:1a6lzf... default is sha256 thought

  • fileSize :: Integer

    File size of compressed nar file. NOTE: du -b

  • narHash :: hash

    Hash of the decompressed nar file. NOTE: to compute use "nix-hash --type sha256 --flat --base32" (srk) this isn't fixed to sha256 but a prefix indicates the type e.g.: sha256:1a6lzf... default is sha256 thought

  • narSize :: Integer

    File size of decompressed nar file. NOTE: du -b

  • references :: Set fp

    Immediate dependencies of the storePath. NOTE: nix-store -q --references

  • deriver :: Maybe txt

    Relative store path (to nix store root) of the deriver. NOTE: nix-store -q --deriver

  • system :: Maybe txt

    System

  • sig :: Maybe txt

    Signature of fields: storePath, narHash, narSize, refs.

  • ca :: Maybe txt

    Content-addressed Store path is computed from a cryptographic hash of the contents of the path, plus some other bits of data like the "name" part of the path.

Instances
(Eq fp, Eq txt, Eq hash) => Eq (NarInfo fp txt hash) Source # 
Instance details

Defined in Nix.NarInfo.Types

Methods

(==) :: NarInfo fp txt hash -> NarInfo fp txt hash -> Bool #

(/=) :: NarInfo fp txt hash -> NarInfo fp txt hash -> Bool #

(Show fp, Show txt, Show hash) => Show (NarInfo fp txt hash) Source # 
Instance details

Defined in Nix.NarInfo.Types

Methods

showsPrec :: Int -> NarInfo fp txt hash -> ShowS #

show :: NarInfo fp txt hash -> String #

showList :: [NarInfo fp txt hash] -> ShowS #

Generic (NarInfo fp txt hash) Source # 
Instance details

Defined in Nix.NarInfo.Types

Associated Types

type Rep (NarInfo fp txt hash) :: Type -> Type #

Methods

from :: NarInfo fp txt hash -> Rep (NarInfo fp txt hash) x #

to :: Rep (NarInfo fp txt hash) x -> NarInfo fp txt hash #

type Rep (NarInfo fp txt hash) Source # 
Instance details

Defined in Nix.NarInfo.Types