| Copyright | (c) Colin Woodbury 2012 - 2020 |
|---|---|
| License | GPL3 |
| Maintainer | Colin Woodbury <colin@fosskers.ca> |
| Safe Haskell | None |
| Language | Haskell2010 |
Aura.Types
Description
Core Aura types.
Synopsis
- data Package
- pname :: Package -> PkgName
- pprov :: Package -> Provides
- pver :: Package -> Versioning
- dividePkgs :: NESet Package -> These (NESet Prebuilt) (NESet Buildable)
- data Dep = Dep {
- name :: !PkgName
- demand :: !VersionDemand
- parseDep :: Text -> Maybe Dep
- renderedDep :: Dep -> Text
- data Buildable = Buildable {}
- data Prebuilt = Prebuilt {}
- data SimplePkg = SimplePkg {
- name :: !PkgName
- version :: !Versioning
- simplepkg :: PackagePath -> Maybe SimplePkg
- simplepkg' :: Text -> Maybe SimplePkg
- class Flagable a where
- data VersionDemand
- _VersionDemand :: Traversal' VersionDemand Versioning
- data InstallType
- data DepError
- newtype Failure = Failure {}
- data Language
- newtype PkgName = PkgName {}
- newtype PkgGroup = PkgGroup {}
- newtype Provides = Provides {}
- newtype PackagePath = PackagePath {}
- 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.
Constructors
| Dep | |
Fields
| |
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-2.1.0-9cTDkrxcFUh23Q42HQr0Vi" False) (C1 (MetaCons "Dep" PrefixI True) (S1 (MetaSel (Just "name") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 PkgName) :*: S1 (MetaSel (Just "demand") 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.
Constructors
| Buildable | |
Instances
| Eq Buildable Source # | |
| Ord Buildable Source # | |
| Show Buildable Source # | |
| Generic Buildable Source # | |
| type Rep Buildable Source # | |
Defined in Aura.Types type Rep Buildable = D1 (MetaData "Buildable" "Aura.Types" "aura-2.1.0-9cTDkrxcFUh23Q42HQr0Vi" False) (C1 (MetaCons "Buildable" PrefixI True) ((S1 (MetaSel (Just "name") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 PkgName) :*: (S1 (MetaSel (Just "version") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Versioning) :*: S1 (MetaSel (Just "base") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 PkgName))) :*: ((S1 (MetaSel (Just "provides") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Provides) :*: S1 (MetaSel (Just "deps") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 [Dep])) :*: (S1 (MetaSel (Just "pkgbuild") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Pkgbuild) :*: S1 (MetaSel (Just "isExplicit") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Bool))))) | |
A prebuilt Package from the official Arch repositories.
Constructors
| Prebuilt | |
Instances
| Eq Prebuilt Source # | |
| Ord Prebuilt Source # | |
Defined in Aura.Types | |
| Show Prebuilt Source # | |
| Generic Prebuilt Source # | |
| type Rep Prebuilt Source # | |
Defined in Aura.Types type Rep Prebuilt = D1 (MetaData "Prebuilt" "Aura.Types" "aura-2.1.0-9cTDkrxcFUh23Q42HQr0Vi" False) (C1 (MetaCons "Prebuilt" PrefixI True) ((S1 (MetaSel (Just "name") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 PkgName) :*: S1 (MetaSel (Just "version") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Versioning)) :*: (S1 (MetaSel (Just "base") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 PkgName) :*: S1 (MetaSel (Just "provides") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Provides)))) | |
A package name with its version number.
Constructors
| SimplePkg | |
Fields
| |
Instances
| Eq SimplePkg Source # | |
| Ord SimplePkg Source # | |
| Show SimplePkg Source # | |
| Generic SimplePkg Source # | |
| type Rep SimplePkg Source # | |
Defined in Aura.Types type Rep SimplePkg = D1 (MetaData "SimplePkg" "Aura.Types" "aura-2.1.0-9cTDkrxcFUh23Q42HQr0Vi" False) (C1 (MetaCons "SimplePkg" PrefixI True) (S1 (MetaSel (Just "name") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 PkgName) :*: S1 (MetaSel (Just "version") 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 Methods asFlag :: ColourMode -> [Text] Source # | |
| Flagable CommonSwitch Source # | |
Defined in Aura.Settings Methods asFlag :: CommonSwitch -> [Text] Source # | |
| Flagable CommonConfig Source # | |
Defined in Aura.Settings Methods 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.
Constructors
| LessThan Versioning | |
| AtLeast Versioning | |
| MoreThan Versioning | |
| MustBe Versioning | |
| Anything |
Instances
| Eq VersionDemand Source # | |
Defined in Aura.Types Methods (==) :: VersionDemand -> VersionDemand -> Bool # (/=) :: VersionDemand -> VersionDemand -> Bool # | |
| Ord VersionDemand Source # | |
Defined in Aura.Types Methods 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 Methods 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 | |
Errors
The various ways that dependency resolution can fail.
Constructors
| NonExistant PkgName | |
| VerConflict (Doc AnsiStyle) | |
| Ignored (Doc AnsiStyle) | |
| BrokenProvides PkgName Provides PkgName |
Some failure message that when given the current runtime Language
will produce a human-friendly error.
Instances
| Show Failure Source # | |
| Exception Failure Source # | |
Defined in Aura.Types Methods toException :: Failure -> SomeException # fromException :: SomeException -> Maybe Failure # displayException :: Failure -> String # | |
Language
All human languages available for text output.
Constructors
| English | |
| Japanese | |
| Polish | |
| Croatian | |
| Swedish | |
| German | |
| Spanish | |
| Portuguese | |
| French | |
| Russian | |
| Italian | |
| Serbian | |
| Norwegian | |
| Indonesia | |
| Chinese | |
| Esperanto |
Instances
| Bounded Language Source # | |
| Enum Language Source # | |
| Eq Language Source # | |
| Ord Language Source # | |
Defined in Aura.Types | |
| 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 Methods fromString :: String -> PkgName # | |
| Generic PkgName Source # | |
| ToJSONKey PkgName Source # | |
Defined in Aura.Types | |
| FromJSONKey PkgName Source # | |
Defined in Aura.Types Methods | |
| 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).
newtype 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
Constructors
| PackagePath | |
Instances
| Eq PackagePath Source # | |
Defined in Aura.Types | |
| Ord PackagePath Source # | If they have the same package names, compare by their versions. Otherwise, do raw comparison of the path string. |
Defined in Aura.Types Methods compare :: PackagePath -> PackagePath -> Ordering # (<) :: PackagePath -> PackagePath -> Bool # (<=) :: PackagePath -> PackagePath -> Bool # (>) :: PackagePath -> PackagePath -> Bool # (>=) :: PackagePath -> PackagePath -> Bool # max :: PackagePath -> PackagePath -> PackagePath # min :: PackagePath -> PackagePath -> PackagePath # | |
| Generic PackagePath Source # | |
Defined in Aura.Types Associated Types type Rep PackagePath :: Type -> Type # | |
| type Rep PackagePath Source # | |
Defined in Aura.Types type Rep PackagePath = D1 (MetaData "PackagePath" "Aura.Types" "aura-2.1.0-9cTDkrxcFUh23Q42HQr0Vi" True) (C1 (MetaCons "PackagePath" PrefixI True) (S1 (MetaSel (Just "path") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (Path Absolute)))) | |
The contents of a PKGBUILD file.
Constructors
| Pkgbuild | |
Fields | |
Instances
| Eq Pkgbuild Source # | |
| Ord Pkgbuild Source # | |
Defined in Aura.Types | |
| Show Pkgbuild Source # | |
| Generic Pkgbuild Source # | |
| type Rep Pkgbuild Source # | |
Defined in Aura.Types type Rep Pkgbuild = D1 (MetaData "Pkgbuild" "Aura.Types" "aura-2.1.0-9cTDkrxcFUh23Q42HQr0Vi" True) (C1 (MetaCons "Pkgbuild" PrefixI True) (S1 (MetaSel (Just "pkgbuild") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 ByteString))) | |