| Safe Haskell | None | 
|---|---|
| Language | Haskell2010 | 
Stack.Types.Resolver
- type Resolver = ResolverWith (Either Request FilePath)
 - data IsLoaded
 - type LoadedResolver = ResolverWith SnapshotHash
 - data ResolverWith customContents
- = ResolverSnapshot !SnapName
 - | ResolverCompiler !(CompilerVersion CVWanted)
 - | ResolverCustom !Text !customContents
 
 - parseResolverText :: Text -> ResolverWith ()
 - data AbstractResolver
- = ARLatestNightly
 - | ARLatestLTS
 - | ARLatestLTSMajor !Int
 - | ARResolver !(ResolverWith ())
 - | ARGlobal
 
 - readAbstractResolver :: ReadM AbstractResolver
 - resolverRawName :: ResolverWith a -> Text
 - data SnapName
 - data Snapshots = Snapshots {
- snapshotsNightly :: !Day
 - snapshotsLts :: !(IntMap Int)
 
 - renderSnapName :: SnapName -> Text
 - parseSnapName :: MonadThrow m => Text -> m SnapName
 - data SnapshotHash
 - trimmedSnapshotHash :: SnapshotHash -> Text
 - snapshotHashToBS :: SnapshotHash -> ByteString
 - snapshotHashFromBS :: ByteString -> SnapshotHash
 - snapshotHashFromDigest :: Digest SHA256 -> SnapshotHash
 - parseCustomLocation :: MonadThrow m => Maybe (Path Abs Dir) -> ResolverWith () -> m Resolver
 
Documentation
data ResolverWith customContents Source #
How we resolve which dependencies to install given a set of packages.
Constructors
| ResolverSnapshot !SnapName | Use an official snapshot from the Stackage project, either an LTS Haskell or Stackage Nightly.  | 
| ResolverCompiler !(CompilerVersion CVWanted) | Require a specific compiler version, but otherwise provide no build plan. Intended for use cases where end user wishes to specify all upstream dependencies manually, such as using a dependency solver.  | 
| ResolverCustom !Text !customContents | A custom resolver based on the given location (as a raw URL
 or filepath). If   | 
Instances
| Functor ResolverWith Source # | |
| Foldable ResolverWith Source # | |
| Traversable ResolverWith Source # | |
| NFData LoadedResolver Source # | |
| Store LoadedResolver Source # | |
| Eq customContents => Eq (ResolverWith customContents) Source # | |
| Data customContents => Data (ResolverWith customContents) Source # | |
| Show customContents => Show (ResolverWith customContents) Source # | |
| Generic (ResolverWith customContents) Source # | |
| ToJSON (ResolverWith a) Source # | |
| (~) * a () => FromJSON (ResolverWith a) Source # | |
| type Rep (ResolverWith customContents) Source # | |
parseResolverText :: Text -> ResolverWith () Source #
Parse a Resolver from a Text
data AbstractResolver Source #
Either an actual resolver value, or an abstract description of one (e.g., latest nightly).
Constructors
| ARLatestNightly | |
| ARLatestLTS | |
| ARLatestLTSMajor !Int | |
| ARResolver !(ResolverWith ()) | |
| ARGlobal | 
Instances
resolverRawName :: ResolverWith a -> Text Source #
Convert a Resolver into its Text representation for human
 presentation. When possible, you should prefer sdResolverName, as
 it will handle the human-friendly name inside a custom snapshot.
The name of an LTS Haskell or Stackage Nightly snapshot.
Most recent Nightly and newest LTS version per major release.
Constructors
| Snapshots | |
Fields 
  | |
renderSnapName :: SnapName -> Text Source #
Convert a SnapName into its short representation, e.g. lts-2.8,
 nightly-2015-03-05.
parseSnapName :: MonadThrow m => Text -> m SnapName Source #
Parse the short representation of a SnapName.
data SnapshotHash Source #
trimmedSnapshotHash :: SnapshotHash -> Text Source #
Return the first 12 characters of the hash as a B64URL-encoded string.
snapshotHashToBS :: SnapshotHash -> ByteString Source #
Return the raw bytes in the hash
snapshotHashFromBS :: ByteString -> SnapshotHash Source #
Create a new SnapshotHash by SHA256 hashing the given contents
snapshotHashFromDigest :: Digest SHA256 -> SnapshotHash Source #
Create a new SnapshotHash from the given digest
Arguments
| :: MonadThrow m | |
| => Maybe (Path Abs Dir) | directory config value was read from  | 
| -> ResolverWith () | |
| -> m Resolver |