Copyright | (c) Colin Woodbury 2012 - 2020 |
---|---|
License | GPL3 |
Maintainer | Colin Woodbury <colin@fosskers.ca> |
Safe Haskell | None |
Language | Haskell2010 |
Core Aura types.
Synopsis
- data Package
- pname :: Package -> PkgName
- pprov :: Package -> Provides
- pver :: Package -> Versioning
- dividePkgs :: NonEmpty Package -> These (NonEmpty Prebuilt) (NonEmpty Buildable)
- data Dep = Dep {
- dName :: !PkgName
- dDemand :: !VersionDemand
- parseDep :: Text -> Maybe Dep
- renderedDep :: Dep -> Text
- data Buildable = Buildable {}
- data Prebuilt = Prebuilt {}
- data SimplePkg = SimplePkg {
- spName :: !PkgName
- spVersion :: !Versioning
- simplepkg :: PackagePath -> Maybe SimplePkg
- simplepkg' :: Text -> Maybe SimplePkg
- bToSP :: Buildable -> SimplePkg
- pToSP :: Prebuilt -> SimplePkg
- class Flagable a where
- data VersionDemand
- _VersionDemand :: Traversal' VersionDemand Versioning
- data InstallType
- data DepError
- = NonExistant !PkgName !PkgName
- | VerConflict !(Doc AnsiStyle)
- | Ignored !(Doc AnsiStyle)
- | BrokenProvides !PkgName !Provides !PkgName
- data Failure
- newtype FailMsg = FailMsg {}
- data Language
- newtype PkgName = PkgName {}
- newtype PkgGroup = PkgGroup {}
- newtype Provides = Provides {}
- data PackagePath
- packagePath :: FilePath -> Maybe PackagePath
- ppPath :: PackagePath -> FilePath
- newtype Pkgbuild = Pkgbuild {}
- type Environment = Map Text Text
- newtype User = User {}
Package Types
pprov :: Package -> Provides Source #
Other names which allow this Package
to be satisfied as a dependency.
A dependency on another package.
Dep | |
|
Instances
Eq Dep Source # | |
Ord Dep Source # | |
Show Dep Source # | |
Generic Dep Source # | |
type Rep Dep Source # | |
Defined in Aura.Types type Rep Dep = D1 ('MetaData "Dep" "Aura.Types" "aura-3.2.2-EfDvW15jsYHDvKMjiTfN8s" 'False) (C1 ('MetaCons "Dep" 'PrefixI 'True) (S1 ('MetaSel ('Just "dName") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 PkgName) :*: S1 ('MetaSel ('Just "dDemand") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 VersionDemand))) |
parseDep :: Text -> Maybe Dep Source #
Parse a dependency entry as it would appear in a PKGBUILD:
>>> parseDep "pacman>1.2.3" Just (Dep {name = PkgName {name = "pacman"}, demand = >1.2.3})
renderedDep :: Dep -> Text Source #
A Package
from the AUR that's buildable in some way on the user's machine.
Instances
A prebuilt Package
from the official Arch repositories.
Instances
Eq Prebuilt Source # | |
Ord Prebuilt Source # | |
Show Prebuilt Source # | |
Generic Prebuilt Source # | |
type Rep Prebuilt Source # | |
Defined in Aura.Types type Rep Prebuilt = D1 ('MetaData "Prebuilt" "Aura.Types" "aura-3.2.2-EfDvW15jsYHDvKMjiTfN8s" 'False) (C1 ('MetaCons "Prebuilt" 'PrefixI 'True) ((S1 ('MetaSel ('Just "pName") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 PkgName) :*: S1 ('MetaSel ('Just "pVersion") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Versioning)) :*: (S1 ('MetaSel ('Just "pBase") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 PkgName) :*: S1 ('MetaSel ('Just "pProvides") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Provides)))) |
A package name with its version number.
SimplePkg | |
|
Instances
Eq SimplePkg Source # | |
Ord SimplePkg Source # | |
Defined in Aura.Types | |
Show SimplePkg Source # | |
Generic SimplePkg Source # | |
type Rep SimplePkg Source # | |
Defined in Aura.Types type Rep SimplePkg = D1 ('MetaData "SimplePkg" "Aura.Types" "aura-3.2.2-EfDvW15jsYHDvKMjiTfN8s" 'False) (C1 ('MetaCons "SimplePkg" 'PrefixI 'True) (S1 ('MetaSel ('Just "spName") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 PkgName) :*: S1 ('MetaSel ('Just "spVersion") 'NoSourceUnpackedness 'SourceStrict 'DecidedStrict) (Rec0 Versioning))) |
simplepkg :: PackagePath -> Maybe SimplePkg Source #
Attempt to create a SimplePkg
from filepaths like
/var/cache/pacman/pkg/linux-3.2.14-1-x86_64.pkg.tar.xz
simplepkg' :: Text -> Maybe SimplePkg Source #
Attempt to create a SimplePkg
from text like:
xchat 2.8.8-19
Typeclasses
class Flagable a where Source #
Types whose members can be converted to CLI flags.
Instances
Flagable Text Source # | |
Flagable PkgGroup Source # | |
Flagable PkgName Source # | |
Flagable ColourMode Source # | |
Defined in Aura.Settings asFlag :: ColourMode -> [Text] Source # | |
Flagable CommonSwitch Source # | |
Defined in Aura.Settings asFlag :: CommonSwitch -> [Text] Source # | |
Flagable CommonConfig Source # | |
Defined in Aura.Settings asFlag :: CommonConfig -> [Text] Source # | |
Flagable Makepkg Source # | |
(Foldable f, Flagable a) => Flagable (f a) Source # | |
Defined in Aura.Types |
Package Building
data VersionDemand Source #
The versioning requirement of some package's dependency.
Instances
Eq VersionDemand Source # | |
Defined in Aura.Types (==) :: VersionDemand -> VersionDemand -> Bool # (/=) :: VersionDemand -> VersionDemand -> Bool # | |
Ord VersionDemand Source # | |
Defined in Aura.Types compare :: VersionDemand -> VersionDemand -> Ordering # (<) :: VersionDemand -> VersionDemand -> Bool # (<=) :: VersionDemand -> VersionDemand -> Bool # (>) :: VersionDemand -> VersionDemand -> Bool # (>=) :: VersionDemand -> VersionDemand -> Bool # max :: VersionDemand -> VersionDemand -> VersionDemand # min :: VersionDemand -> VersionDemand -> VersionDemand # | |
Show VersionDemand Source # | |
Defined in Aura.Types showsPrec :: Int -> VersionDemand -> ShowS # show :: VersionDemand -> String # showList :: [VersionDemand] -> ShowS # |
_VersionDemand :: Traversal' VersionDemand Versioning Source #
Attempt to zoom into the Versioning
hiding within a VersionDemand
.
data InstallType Source #
The installation method.
Instances
Eq InstallType Source # | |
Defined in Aura.Types (==) :: InstallType -> InstallType -> Bool # (/=) :: InstallType -> InstallType -> Bool # |
Errors
The various ways that dependency resolution can fail.
Failures that can occur during Aura processing. Could be a message, or a silent failure that should print nothing to the console.
Instances
Show Failure Source # | |
Exception Failure Source # | |
Defined in Aura.Types toException :: Failure -> SomeException # fromException :: SomeException -> Maybe Failure # displayException :: Failure -> String # |
Some failure message that when given the current runtime Language
will produce a human-friendly error.
Instances
Show FailMsg Source # | |
Exception FailMsg Source # | |
Defined in Aura.Types toException :: FailMsg -> SomeException # fromException :: SomeException -> Maybe FailMsg # displayException :: FailMsg -> String # |
Language
All human languages available for text output.
English | |
Japanese | |
Polish | |
Croatian | |
Swedish | |
German | |
Spanish | |
Portuguese | |
French | |
Russian | |
Italian | |
Serbian | |
Norwegian | |
Indonesia | |
Chinese | |
Esperanto | |
Dutch |
Instances
Bounded Language Source # | |
Enum Language Source # | |
Eq Language Source # | |
Ord Language Source # | |
Show Language Source # | |
Other Wrappers
The name of an Arch Linux package.
Instances
Eq PkgName Source # | |
Ord PkgName Source # | |
Show PkgName Source # | |
IsString PkgName Source # | |
Defined in Aura.Types fromString :: String -> PkgName # | |
Generic PkgName Source # | |
ToJSONKey PkgName Source # | |
Defined in Aura.Types | |
FromJSONKey PkgName Source # | |
Defined in Aura.Types | |
Flagable PkgName Source # | |
type Rep PkgName Source # | |
Defined in Aura.Types |
A group that a Package
could belong too, like base
, base-devel
, etc.
The dependency which some package provides. May not be the same name as the package itself (e.g. cronie provides cron).
data PackagePath Source #
Filepaths like:
- /var/cache/pacman/pkg/linux-3.2.14-1-x86_64.pkg.tar.xz
- /var/cache/pacman/pkg/wine-1.4rc6-1-x86_64.pkg.tar.xz
- /var/cache/pacman/pkg/ruby-1.9.3_p125-4-x86_64.pkg.tar.xz
Instances
packagePath :: FilePath -> Maybe PackagePath Source #
Smart constructor for PackagePath
.
ppPath :: PackagePath -> FilePath Source #
The contents of a PKGBUILD file.
Instances
Eq Pkgbuild Source # | |
Ord Pkgbuild Source # | |
Show Pkgbuild Source # | |
Generic Pkgbuild Source # | |
type Rep Pkgbuild Source # | |
Defined in Aura.Types type Rep Pkgbuild = D1 ('MetaData "Pkgbuild" "Aura.Types" "aura-3.2.2-EfDvW15jsYHDvKMjiTfN8s" 'True) (C1 ('MetaCons "Pkgbuild" 'PrefixI 'True) (S1 ('MetaSel ('Just "pkgbuild") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ByteString))) |