hnix-store-core-0.8.0.0: Core types used for interacting with the Nix store.
Safe HaskellSafe-Inferred
LanguageHaskell2010

System.Nix.ContentAddress

Synopsis

Documentation

data ContentAddress Source #

An address for a content-addressable store path, i.e. one whose store path hash is purely a function of its contents (as opposed to paths that are derivation outputs, whose hashes are a function of the contents of the derivation file instead).

For backwards-compatibility reasons, the same information is encodable in multiple ways, depending on the method used to add the path to the store. These unfortunately result in separate store paths.

Instances

Instances details
Generic ContentAddress Source # 
Instance details

Defined in System.Nix.ContentAddress

Associated Types

type Rep ContentAddress :: Type -> Type #

Show ContentAddress Source # 
Instance details

Defined in System.Nix.ContentAddress

Eq ContentAddress Source # 
Instance details

Defined in System.Nix.ContentAddress

Ord ContentAddress Source # 
Instance details

Defined in System.Nix.ContentAddress

type Rep ContentAddress Source # 
Instance details

Defined in System.Nix.ContentAddress

type Rep ContentAddress = D1 ('MetaData "ContentAddress" "System.Nix.ContentAddress" "hnix-store-core-0.8.0.0-2YQUX8JlMxk93e1fw1Y66G" 'False) (C1 ('MetaCons "ContentAddress" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ContentAddressMethod) :*: S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (DSum HashAlgo Digest))))

data ContentAddressMethod Source #

Instances

Instances details
Generic ContentAddressMethod Source # 
Instance details

Defined in System.Nix.ContentAddress

Associated Types

type Rep ContentAddressMethod :: Type -> Type #

Show ContentAddressMethod Source # 
Instance details

Defined in System.Nix.ContentAddress

Eq ContentAddressMethod Source # 
Instance details

Defined in System.Nix.ContentAddress

Ord ContentAddressMethod Source # 
Instance details

Defined in System.Nix.ContentAddress

type Rep ContentAddressMethod Source # 
Instance details

Defined in System.Nix.ContentAddress

type Rep ContentAddressMethod = D1 ('MetaData "ContentAddressMethod" "System.Nix.ContentAddress" "hnix-store-core-0.8.0.0-2YQUX8JlMxk93e1fw1Y66G" 'False) (C1 ('MetaCons "FileIngestionMethod" 'PrefixI 'False) (S1 ('MetaSel ('Nothing :: Maybe Symbol) 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 FileIngestionMethod)) :+: C1 ('MetaCons "TextIngestionMethod" 'PrefixI 'False) (U1 :: Type -> Type))

data FileIngestionMethod Source #

Add path recursively or not

Instances

Instances details
Bounded FileIngestionMethod Source # 
Instance details

Defined in System.Nix.Store.Types

Enum FileIngestionMethod Source # 
Instance details

Defined in System.Nix.Store.Types

Generic FileIngestionMethod Source # 
Instance details

Defined in System.Nix.Store.Types

Associated Types

type Rep FileIngestionMethod :: Type -> Type #

Show FileIngestionMethod Source # 
Instance details

Defined in System.Nix.Store.Types

Eq FileIngestionMethod Source # 
Instance details

Defined in System.Nix.Store.Types

Ord FileIngestionMethod Source # 
Instance details

Defined in System.Nix.Store.Types

type Rep FileIngestionMethod Source # 
Instance details

Defined in System.Nix.Store.Types

type Rep FileIngestionMethod = D1 ('MetaData "FileIngestionMethod" "System.Nix.Store.Types" "hnix-store-core-0.8.0.0-2YQUX8JlMxk93e1fw1Y66G" 'False) (C1 ('MetaCons "FileIngestionMethod_Flat" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "FileIngestionMethod_FileRecursive" 'PrefixI 'False) (U1 :: Type -> Type))

contentAddressParser :: Parser ContentAddress Source #

Parser for content addressable field

buildContentAddress :: ContentAddress -> Text Source #

Marshall ContentAddressableAddress to Text in form suitable for remote protocol usage.

parseContentAddress :: Text -> Either String ContentAddress Source #

Parse ContentAddressableAddress from ByteString