-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | A secure package manager for Arch Linux and the AUR, written in Haskell.
--
-- Aura is a package manager for Arch Linux written in Haskell. It
-- connects to both the official Arch repostitories and to the AUR,
-- allowing easy control of all packages on an Arch system. It allows
-- all pacman operations and provides new custom ones for
-- dealing with AUR packages. This differs from some other AUR package
-- managers.
@package aura
@version 2.0.4
-- | Annotate Doc text with various colours.
module Aura.Colour
-- | Render an assembled Doc into strict Text.
dtot :: Doc AnsiStyle -> Text
-- | Colour a Doc cyan.
cyan :: Doc AnsiStyle -> Doc AnsiStyle
-- | Colour a Doc cyan and bold.
bCyan :: Doc AnsiStyle -> Doc AnsiStyle
-- | Colour a Doc green.
green :: Doc AnsiStyle -> Doc AnsiStyle
-- | Colour a Doc yellow.
yellow :: Doc AnsiStyle -> Doc AnsiStyle
-- | Colour a Doc red.
red :: Doc AnsiStyle -> Doc AnsiStyle
-- | Colour a Doc magenta.
magenta :: Doc AnsiStyle -> Doc AnsiStyle
-- | Core Aura types.
module Aura.Types
-- | A package to be installed.
data Package
FromRepo :: Prebuilt -> Package
FromAUR :: Buildable -> Package
-- | The name of a Package.
pname :: Package -> PkgName
-- | Other names which allow this Package to be satisfied as a
-- dependency.
pprov :: Package -> Provides
-- | The version of a Package.
pver :: Package -> Versioning
dividePkgs :: NESet Package -> These (NESet Prebuilt) (NESet Buildable)
-- | A dependency on another package.
data Dep
Dep :: !PkgName -> !VersionDemand -> Dep
[$sel:name:Dep] :: Dep -> !PkgName
[$sel:demand:Dep] :: Dep -> !VersionDemand
-- | 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})
--
parseDep :: Text -> Maybe Dep
-- | Renders the Dep into a form that pacman -T
-- understands. The dual of parseDep.
renderedDep :: Dep -> Text
-- | A Package from the AUR that's buildable in some way on the
-- user's machine.
data Buildable
Buildable :: !PkgName -> !Versioning -> !PkgName -> !Provides -> ![Dep] -> !Pkgbuild -> !Bool -> Buildable
[$sel:name:Buildable] :: Buildable -> !PkgName
[$sel:version:Buildable] :: Buildable -> !Versioning
[$sel:base:Buildable] :: Buildable -> !PkgName
[$sel:provides:Buildable] :: Buildable -> !Provides
[$sel:deps:Buildable] :: Buildable -> ![Dep]
[$sel:pkgbuild:Buildable] :: Buildable -> !Pkgbuild
[$sel:isExplicit:Buildable] :: Buildable -> !Bool
-- | A prebuilt Package from the official Arch repositories.
data Prebuilt
Prebuilt :: !PkgName -> !Versioning -> !PkgName -> !Provides -> Prebuilt
[$sel:name:Prebuilt] :: Prebuilt -> !PkgName
[$sel:version:Prebuilt] :: Prebuilt -> !Versioning
[$sel:base:Prebuilt] :: Prebuilt -> !PkgName
[$sel:provides:Prebuilt] :: Prebuilt -> !Provides
-- | A package name with its version number.
data SimplePkg
SimplePkg :: !PkgName -> !Versioning -> SimplePkg
[$sel:name:SimplePkg] :: SimplePkg -> !PkgName
[$sel:version:SimplePkg] :: SimplePkg -> !Versioning
-- | Attempt to create a SimplePkg from filepaths like
-- /var/cache/pacman/pkg/linux-3.2.14-1-x86_64.pkg.tar.xz
simplepkg :: PackagePath -> Maybe SimplePkg
-- | Attempt to create a SimplePkg from text like: xchat 2.8.8-19
simplepkg' :: Text -> Maybe SimplePkg
-- | Types whose members can be converted to CLI flags.
class Flagable a
asFlag :: Flagable a => a -> [Text]
-- | The versioning requirement of some package's dependency.
data VersionDemand
LessThan :: Versioning -> VersionDemand
AtLeast :: Versioning -> VersionDemand
MoreThan :: Versioning -> VersionDemand
MustBe :: Versioning -> VersionDemand
Anything :: VersionDemand
-- | Attempt to zoom into the Versioning hiding within a
-- VersionDemand.
_VersionDemand :: Traversal' VersionDemand Versioning
-- | The installation method.
data InstallType
Pacman :: PkgName -> InstallType
Build :: Buildable -> InstallType
-- | The various ways that dependency resolution can fail.
data DepError
NonExistant :: PkgName -> DepError
VerConflict :: Doc AnsiStyle -> DepError
Ignored :: Doc AnsiStyle -> DepError
BrokenProvides :: PkgName -> Provides -> PkgName -> DepError
-- | Some failure message that when given the current runtime
-- Language will produce a human-friendly error.
newtype Failure
Failure :: (Language -> Doc AnsiStyle) -> Failure
[$sel:failure:Failure] :: Failure -> Language -> Doc AnsiStyle
-- | All human languages available for text output.
data Language
English :: Language
Japanese :: Language
Polish :: Language
Croatian :: Language
Swedish :: Language
German :: Language
Spanish :: Language
Portuguese :: Language
French :: Language
Russian :: Language
Italian :: Language
Serbian :: Language
Norwegian :: Language
Indonesia :: Language
Chinese :: Language
Esperanto :: Language
-- | The name of an Arch Linux package.
newtype PkgName
PkgName :: Text -> PkgName
[$sel:name:PkgName] :: PkgName -> Text
-- | A group that a Package could belong too, like base,
-- base-devel, etc.
newtype PkgGroup
PkgGroup :: Text -> PkgGroup
[$sel:group:PkgGroup] :: PkgGroup -> Text
-- | The dependency which some package provides. May not be the same name
-- as the package itself (e.g. cronie provides cron).
newtype Provides
Provides :: PkgName -> Provides
[$sel:provides:Provides] :: Provides -> PkgName
-- | 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
--
newtype PackagePath
PackagePath :: Path Absolute -> PackagePath
[$sel:path:PackagePath] :: PackagePath -> Path Absolute
-- | The contents of a PKGBUILD file.
newtype Pkgbuild
Pkgbuild :: ByteString -> Pkgbuild
[$sel:pkgbuild:Pkgbuild] :: Pkgbuild -> ByteString
-- | Shell environment variables.
type Environment = Map Text Text
-- | The name of a user account on a Linux system.
newtype User
User :: Text -> User
[$sel:user:User] :: User -> Text
instance GHC.Classes.Eq Aura.Types.Package
instance GHC.Classes.Eq Aura.Types.InstallType
instance GHC.Generics.Generic Aura.Types.Buildable
instance GHC.Show.Show Aura.Types.Buildable
instance GHC.Classes.Ord Aura.Types.Buildable
instance GHC.Classes.Eq Aura.Types.Buildable
instance GHC.Generics.Generic Aura.Types.Prebuilt
instance GHC.Show.Show Aura.Types.Prebuilt
instance GHC.Classes.Ord Aura.Types.Prebuilt
instance GHC.Classes.Eq Aura.Types.Prebuilt
instance GHC.Generics.Generic Aura.Types.Provides
instance GHC.Show.Show Aura.Types.Provides
instance GHC.Classes.Ord Aura.Types.Provides
instance GHC.Classes.Eq Aura.Types.Provides
instance Aura.Types.Flagable Aura.Types.PkgGroup
instance GHC.Generics.Generic Aura.Types.PkgGroup
instance GHC.Show.Show Aura.Types.PkgGroup
instance GHC.Classes.Ord Aura.Types.PkgGroup
instance GHC.Classes.Eq Aura.Types.PkgGroup
instance GHC.Generics.Generic Aura.Types.Dep
instance GHC.Show.Show Aura.Types.Dep
instance GHC.Classes.Ord Aura.Types.Dep
instance GHC.Classes.Eq Aura.Types.Dep
instance GHC.Generics.Generic Aura.Types.SimplePkg
instance GHC.Show.Show Aura.Types.SimplePkg
instance GHC.Classes.Ord Aura.Types.SimplePkg
instance GHC.Classes.Eq Aura.Types.SimplePkg
instance Data.String.IsString Aura.Types.PkgName
instance Data.Aeson.Types.FromJSON.FromJSONKey Aura.Types.PkgName
instance Data.Aeson.Types.ToJSON.ToJSONKey Aura.Types.PkgName
instance Aura.Types.Flagable Aura.Types.PkgName
instance GHC.Generics.Generic Aura.Types.PkgName
instance GHC.Show.Show Aura.Types.PkgName
instance GHC.Classes.Ord Aura.Types.PkgName
instance GHC.Classes.Eq Aura.Types.PkgName
instance GHC.Generics.Generic Aura.Types.User
instance GHC.Show.Show Aura.Types.User
instance GHC.Classes.Eq Aura.Types.User
instance GHC.Show.Show Aura.Types.Language
instance GHC.Classes.Ord Aura.Types.Language
instance GHC.Enum.Bounded Aura.Types.Language
instance GHC.Enum.Enum Aura.Types.Language
instance GHC.Classes.Eq Aura.Types.Language
instance GHC.Generics.Generic Aura.Types.Pkgbuild
instance GHC.Show.Show Aura.Types.Pkgbuild
instance GHC.Classes.Ord Aura.Types.Pkgbuild
instance GHC.Classes.Eq Aura.Types.Pkgbuild
instance GHC.Generics.Generic Aura.Types.PackagePath
instance GHC.Classes.Eq Aura.Types.PackagePath
instance GHC.Classes.Ord Aura.Types.VersionDemand
instance GHC.Classes.Eq Aura.Types.VersionDemand
instance GHC.Classes.Ord Aura.Types.Package
instance GHC.Exception.Type.Exception Aura.Types.Failure
instance GHC.Show.Show Aura.Types.Failure
instance GHC.Classes.Ord Aura.Types.PackagePath
instance GHC.Show.Show Aura.Types.VersionDemand
instance Aura.Types.Flagable Data.Text.Internal.Text
instance (Data.Foldable.Foldable f, Aura.Types.Flagable a) => Aura.Types.Flagable (f a)
-- | Definition of the runtime environment.
module Aura.Settings
-- | The global settings as set by the user with command-line flags.
data Settings
Settings :: !Manager -> !Environment -> !Language -> !FilePath -> !Bool -> !Set PkgName -> !CommonConfig -> !BuildConfig -> Settings
[managerOf] :: Settings -> !Manager
[envOf] :: Settings -> !Environment
[langOf] :: Settings -> !Language
[editorOf] :: Settings -> !FilePath
[isTerminal] :: Settings -> !Bool
[ignoresOf] :: Settings -> !Set PkgName
[commonConfigOf] :: Settings -> !CommonConfig
[buildConfigOf] :: Settings -> !BuildConfig
-- | Settings unique to the AUR package building process.
data BuildConfig
BuildConfig :: !Set Makepkg -> !Path Absolute -> !Maybe User -> !Truncation -> !Set BuildSwitch -> BuildConfig
[makepkgFlagsOf] :: BuildConfig -> !Set Makepkg
[buildPathOf] :: BuildConfig -> !Path Absolute
[buildUserOf] :: BuildConfig -> !Maybe User
[truncationOf] :: BuildConfig -> !Truncation
[buildSwitchesOf] :: BuildConfig -> !Set BuildSwitch
-- | Extra options for customizing the build process.
data BuildSwitch
DeleteMakeDeps :: BuildSwitch
DiffPkgbuilds :: BuildSwitch
DontSuppressMakepkg :: BuildSwitch
DryRun :: BuildSwitch
HotEdit :: BuildSwitch
LowVerbosity :: BuildSwitch
RebuildDevel :: BuildSwitch
SortAlphabetically :: BuildSwitch
UseCustomizepkg :: BuildSwitch
ForceBuilding :: BuildSwitch
NoPkgbuildCheck :: BuildSwitch
-- | Is some Aura-specific setting turned on for this run?
switch :: Settings -> BuildSwitch -> Bool
-- | How -As should truncate its results.
data Truncation
None :: Truncation
Head :: Word -> Truncation
Tail :: Word -> Truncation
-- | Unless otherwise specified, packages will be built within
-- /tmp.
defaultBuildDir :: Path Absolute
-- | Flags that are common to both Aura and Pacman. Aura will react to
-- them, but also pass them through to pacman calls if
-- necessary.
data CommonConfig
CommonConfig :: !Either (Path Absolute) (Path Absolute) -> !Either (Path Absolute) (Path Absolute) -> !Either (Path Absolute) (Path Absolute) -> !Set CommonSwitch -> CommonConfig
[cachePathOf] :: CommonConfig -> !Either (Path Absolute) (Path Absolute)
[configPathOf] :: CommonConfig -> !Either (Path Absolute) (Path Absolute)
[logPathOf] :: CommonConfig -> !Either (Path Absolute) (Path Absolute)
[commonSwitchesOf] :: CommonConfig -> !Set CommonSwitch
-- | Yes/No-style switches that are common to both Aura and Pacman. Aura
-- acts on them first, then passes them down to pacman if
-- necessary.
data CommonSwitch
NoConfirm :: CommonSwitch
NeededOnly :: CommonSwitch
Debug :: CommonSwitch
Colour :: ColourMode -> CommonSwitch
-- | Matches Pacman's colour options. Auto will ensure that text
-- will only be coloured when the output target is a terminal.
data ColourMode
Never :: ColourMode
Always :: ColourMode
Auto :: ColourMode
-- | Is some Aura/Pacman common setting turned on for this run?
shared :: Settings -> CommonSwitch -> Bool
-- | CLI flags that will be passed down to makepkg when building
-- packages.
data Makepkg
IgnoreArch :: Makepkg
AllSource :: Makepkg
SkipInteg :: Makepkg
instance GHC.Show.Show Aura.Settings.BuildConfig
instance GHC.Show.Show Aura.Settings.BuildSwitch
instance GHC.Classes.Ord Aura.Settings.BuildSwitch
instance GHC.Classes.Eq Aura.Settings.BuildSwitch
instance GHC.Generics.Generic Aura.Settings.CommonConfig
instance GHC.Show.Show Aura.Settings.CommonConfig
instance GHC.Show.Show Aura.Settings.CommonSwitch
instance GHC.Classes.Ord Aura.Settings.CommonSwitch
instance GHC.Classes.Eq Aura.Settings.CommonSwitch
instance GHC.Show.Show Aura.Settings.ColourMode
instance GHC.Classes.Ord Aura.Settings.ColourMode
instance GHC.Classes.Eq Aura.Settings.ColourMode
instance GHC.Show.Show Aura.Settings.Makepkg
instance GHC.Classes.Ord Aura.Settings.Makepkg
instance GHC.Classes.Eq Aura.Settings.Makepkg
instance GHC.Show.Show Aura.Settings.Truncation
instance GHC.Classes.Eq Aura.Settings.Truncation
instance Aura.Types.Flagable Aura.Settings.CommonConfig
instance Aura.Types.Flagable Aura.Settings.CommonSwitch
instance Aura.Types.Flagable Aura.Settings.ColourMode
instance Aura.Types.Flagable Aura.Settings.Makepkg
-- | Diffing files.
module Aura.Diff
-- | Given two filepaths, output the diff of the two files. Output will be
-- coloured unless colour is deactivated by `--color never` or by
-- detection of a non-terminal output target.
diff :: MonadIO m => Settings -> Path Absolute -> Path Absolute -> m ()
module Aura.Pkgbuild.Base
-- | The default location: /var/cache/aura/pkgbuilds/
pkgbuildCache :: Path Absolute
-- | The expected path to a stored PKGBUILD, given some package name.
pkgbuildPath :: PkgName -> Path Absolute
-- | Handle the storing of PKGBUILDs.
module Aura.Pkgbuild.Records
-- | Does a given package has a PKGBUILD stored? This is True when a
-- package has been built successfully once before.
hasPkgbuildStored :: PkgName -> IO Bool
-- | Write the PKGBUILDs of some Buildables to disk.
storePkgbuilds :: NESet Buildable -> IO ()
-- | The various fields for -Ai output.
module Aura.Languages.Fields
-- | All output strings that a user can be shown. All normal restrictions
-- on line length do not apply for this file, and this file only.
module Aura.Languages
-- | Analyse PKGBUILDs for potentially malicious bash code.
module Aura.Pkgbuild.Security
-- | A bash term which should never appear in a PKGBUILD. If one does, it's
-- either a sign of maintainer negligence or malicious behaviour.
data BannedTerm
BannedTerm :: Text -> BanCategory -> BannedTerm
-- | The reason why the bash term is black-listed.
data BanCategory
Downloading :: BanCategory
ScriptRunning :: BanCategory
Permissions :: BanCategory
InlinedBash :: BanCategory
StrangeBashism :: BanCategory
CleverRedirect :: BanCategory
-- | Attempt to parse a PKGBUILD. Should succeed for all reasonable
-- PKGBUILDs.
parsedPB :: Pkgbuild -> Maybe List
-- | Discover any banned terms lurking in a parsed PKGBUILD, paired with
-- the surrounding context lines.
bannedTerms :: List -> [(ShellCommand, BannedTerm)]
-- | Dispatch different error messages depending on the category of a
-- BannedTerm.
reportExploit :: BannedTerm -> Language -> Doc AnsiStyle
instance GHC.Generics.Generic Aura.Pkgbuild.Security.BannedTerm
instance GHC.Show.Show Aura.Pkgbuild.Security.BannedTerm
instance GHC.Classes.Ord Aura.Pkgbuild.Security.BannedTerm
instance GHC.Classes.Eq Aura.Pkgbuild.Security.BannedTerm
instance GHC.Show.Show Aura.Pkgbuild.Security.BanCategory
instance GHC.Classes.Ord Aura.Pkgbuild.Security.BanCategory
instance GHC.Classes.Eq Aura.Pkgbuild.Security.BanCategory
-- | An interface to pacman. Takes any pacman arguments and
-- applies it to pacman through the shell.
module Aura.Pacman
-- | Run a pacman action that may fail.
pacman :: [Text] -> IO ()
-- | Runs pacman silently and returns only the stdout.
pacmanOutput :: [Text] -> IO ByteString
-- | Run some pacman process, but only care about whether it
-- succeeded.
pacmanSuccess :: [Text] -> IO Bool
-- | Runs pacman silently and returns the stdout as UTF8-decoded
-- Text lines.
pacmanLines :: [Text] -> IO [Text]
-- | Default location of the pacman database lock file:
-- /var/lib/pacman/db.lck
lockFile :: Path Absolute
-- | Default location of the pacman config file: /etc/pacman.conf
pacmanConfFile :: Path Absolute
-- | Default location of the pacman log flie: /var/log/pacman.log
defaultLogFile :: Path Absolute
-- | Fetches the CacheDir entry from the config, if it's there.
getCachePath :: Config -> Maybe (Path Absolute)
-- | Fetches the LogFile entry from the config, if it's there.
getLogFilePath :: Config -> Maybe (Path Absolute)
-- | The (meaningful) contents of the Pacman config file.
newtype Config
Config :: Map Text [Text] -> Config
-- | Parse a Config, the pacman configuration file.
config :: Parsec Void Text Config
-- | Given a filepath to the pacman config, try to parse its contents.
getPacmanConf :: Path Absolute -> IO (Either Failure Config)
-- | Fetches the IgnorePkg entry from the config, if it's there.
getIgnoredPkgs :: Config -> Set PkgName
-- | Fetches the IgnoreGroup entry from the config, if it's there.
getIgnoredGroups :: Config -> Set PkgGroup
-- | Given a Set of package groups, yield all the packages they
-- contain.
groupPackages :: NESet PkgGroup -> IO (Set PkgName)
-- | Yields the lines given by `pacman -V` with the pacman image stripped.
versionInfo :: IO [Text]
-- | The amount of whitespace before text in the lines given by `pacman -V`
verMsgPad :: Int
instance GHC.Show.Show Aura.Pacman.Config
-- | Reading and searching the package cache.
module Aura.Cache
-- | Every package in the current cache, paired with its original filename.
newtype Cache
Cache :: Map SimplePkg PackagePath -> Cache
[_cache] :: Cache -> Map SimplePkg PackagePath
-- | Given a path to the package cache, yields its contents in a usable
-- form.
cacheContents :: Path Absolute -> IO Cache
-- | The default location of the package cache: /var/cache/pacman/pkg/
defaultPackageCache :: Path Absolute
-- | Any entries (filepaths) in the cache that match a given Text.
cacheMatches :: Settings -> Text -> IO [PackagePath]
-- | All packages from a given Set who have a copy in the cache.
pkgsInCache :: Settings -> NESet PkgName -> IO (Set PkgName)
-- | Utility functions specific to Aura.
module Aura.Utils
-- | For regex-like find-and-replace in some Text.
data Pattern
Pattern :: Text -> Text -> Pattern
[_pattern] :: Pattern -> Text
[_target] :: Pattern -> Text
-- | Replaces a (p)attern with a (t)arget in a line if possible.
replaceByPatt :: [Pattern] -> Text -> Text
-- | Find lines which contain some given Text.
searchLines :: Text -> [Text] -> [Text]
-- | Assumes the given URL is correctly formatted.
urlContents :: Manager -> String -> IO (Maybe ByteString)
-- | Code borrowed from `ansi-terminal` library by Max Bolingbroke.
csi :: [Int] -> ByteString -> ByteString
-- | Terminal code for raising the cursor.
cursorUpLineCode :: Int -> ByteString
-- | Hide the cursor in a terminal.
hideCursor :: IO ()
-- | Restore a cursor to visiblity in the terminal.
showCursor :: IO ()
-- | Raise the cursor by n lines.
raiseCursorBy :: Int -> IO ()
-- | This will get the true user name regardless of sudo-ing.
getTrueUser :: Environment -> Maybe User
-- | vi is a sensible default, it should be installed by on any
-- Arch system.
getEditor :: Environment -> FilePath
-- | This will get the locale variable for translations from the
-- environment
getLocale :: Environment -> Text
-- | Is the user root, or using sudo?
hasRootPriv :: Environment -> Bool
-- | Is the current user of Aura the true root user, and not just
-- a sudo user?
isTrueRoot :: Environment -> Bool
-- | Mark some Path as being owned by a User.
chown :: MonadIO m => User -> Path Absolute -> [String] -> m ()
-- | If a file exists, it performs action t on the argument. | If
-- the file doesn't exist, it performs f and returns the
-- argument.
ifFile :: MonadIO m => (a -> m a) -> m b -> Path Absolute -> a -> m a
-- | Print a Doc with Aura flair after performing a
-- colourCheck.
putStrLnA :: Settings -> Doc AnsiStyle -> IO ()
putText :: Text -> IO ()
putTextLn :: Text -> IO ()
-- | Strip colours from a Doc if --color=never is
-- specified, or if the output target isn't a terminal.
colourCheck :: Settings -> Doc ann -> Doc ann
-- | Format two lists into two nice rows a la `-Qi` or `-Si`.
entrify :: Settings -> [Text] -> [Doc AnsiStyle] -> Doc AnsiStyle
-- | Doesn't prompt when `--noconfirm` is used.
optionalPrompt :: Settings -> (Language -> Doc AnsiStyle) -> IO Bool
-- | Given a number of selections, allows the user to choose one.
getSelection :: Foldable f => (a -> Text) -> f a -> IO a
-- | maybe with the function at the end.
maybe' :: b -> Maybe a -> (a -> b) -> b
-- | Query the AUR for a package's PKGBUILD.
module Aura.Pkgbuild.Fetch
-- | The PKGBUILD of a given package, retrieved from the AUR servers.
getPkgbuild :: Manager -> PkgName -> IO (Maybe Pkgbuild)
-- | The location of a given package's PKGBUILD on the AUR servers.
pkgbuildUrl :: String -> String
-- | For handling the editing of PKGBUILDs.
module Aura.Pkgbuild.Editing
-- | Allow the user to edit the PKGBUILD if they asked to do so.
hotEdit :: Settings -> Buildable -> IO Buildable
-- | Interface to makepkg.
module Aura.MakePkg
-- | Given the current user name, build the package of whatever directory
-- we're in.
makepkg :: Settings -> User -> IO (Either Failure (NESet (Path Absolute)))
-- | Make a source package. See `man makepkg` and grep for `--allsource`.
makepkgSource :: User -> IO [Path Absolute]
-- | The default location of the makepkg configuration: /etc/makepkg.conf
makepkgConfFile :: Path Absolute
-- | Print an animated AURA version message.
module Aura.Logo
-- | Show an animated version message, but only when the output target is a
-- terminal.
animateVersionMsg :: Settings -> Text -> [Text] -> IO ()
instance GHC.Classes.Eq Aura.Logo.MouthState
-- | Core types and functions which belong nowhere else.
module Aura.Core
-- | The complete Aura runtime environment. Repository has internal
-- caches instantiated in IO, while Settings is mostly
-- static and derived from command-line arguments.
data Env
Env :: !Repository -> !Settings -> Env
[repository] :: Env -> !Repository
[settings] :: Env -> !Settings
-- | A Repository is a place where packages may be fetched from.
-- Multiple repositories can be combined with the Semigroup
-- instance. Checks packages in batches for efficiency.
data Repository
Repository :: !TVar (Map PkgName Package) -> (Settings -> NESet PkgName -> IO (Maybe (Set PkgName, Set Package))) -> Repository
[repoCache] :: Repository -> !TVar (Map PkgName Package)
[repoLookup] :: Repository -> Settings -> NESet PkgName -> IO (Maybe (Set PkgName, Set Package))
liftMaybeM :: (MonadThrow m, Exception e) => e -> m (Maybe a) -> m a
-- | Action won't be allowed unless user is root, or using sudo.
sudo :: RIO Env a -> RIO Env a
-- | Stop the user if they are the true root. Building as root isn't
-- allowed since makepkg v4.2.
trueRoot :: RIO Env a -> RIO Env a
-- | A list of non-prebuilt packages installed on the system. `-Qm` yields
-- a list of sorted values.
foreignPackages :: IO (Set SimplePkg)
-- | Packages marked as a dependency, yet are required by no other package.
orphans :: IO (Set PkgName)
-- | Any package whose name is suffixed by git, hg, svn, darcs, cvs, or
-- bzr.
develPkgs :: IO (Set PkgName)
-- | Depedencies which are not installed, or otherwise provided by some
-- installed package.
newtype Unsatisfied
Unsatisfied :: NESet Dep -> Unsatisfied
-- | The opposite of Unsatisfied.
newtype Satisfied
Satisfied :: NESet Dep -> Satisfied
-- | Similar to isSatisfied, but dependencies are checked in a
-- batch, since -T can accept multiple inputs.
areSatisfied :: NESet Dep -> IO (These Unsatisfied Satisfied)
-- | Returns what it was given if the package is already installed.
-- Reasoning: Using raw bools can be less expressive.
isInstalled :: PkgName -> IO (Maybe PkgName)
-- | Block further action until the database is free.
checkDBLock :: Settings -> IO ()
-- | An -Rsu call.
removePkgs :: NESet PkgName -> RIO Env ()
-- | Partition a list of packages into pacman and buildable groups. Yes,
-- this is the correct signature. As far as this function (in isolation)
-- is concerned, there is no way to guarantee that the list of
-- NESets will itself be non-empty.
partitionPkgs :: NonEmpty (NESet Package) -> ([Prebuilt], [NESet Buildable])
-- | Package a Buildable, running the customization handler first.
packageBuildable :: Settings -> Buildable -> IO Package
-- | Print some message in green with Aura flair.
notify :: Settings -> Doc AnsiStyle -> IO ()
-- | Print some message in yellow with Aura flair.
warn :: Settings -> Doc AnsiStyle -> IO ()
-- | Print some message in red with Aura flair.
scold :: Settings -> Doc AnsiStyle -> IO ()
-- | Report a message with multiple associated items. Usually a list of
-- naughty packages.
report :: (Doc AnsiStyle -> Doc AnsiStyle) -> (Language -> Doc AnsiStyle) -> NonEmpty PkgName -> RIO Env ()
instance GHC.Base.Semigroup Aura.Core.Repository
-- | Handle the saving and restoring of installed package states.
module Aura.State
-- | All packages installed at some specific ZonedTime. Any "pinned"
-- PkgState will never be deleted by `-Bc`.
data PkgState
PkgState :: ZonedTime -> Bool -> Map PkgName Versioning -> PkgState
[timeOf] :: PkgState -> ZonedTime
[pinnedOf] :: PkgState -> Bool
[pkgsOf] :: PkgState -> Map PkgName Versioning
-- | Save a package state. In writing the first state file, the
-- states directory is created automatically.
saveState :: Settings -> IO ()
-- | Does its best to restore a state chosen by the user.
restoreState :: RIO Env ()
-- | Does a given package have an entry in a particular PkgState?
inState :: SimplePkg -> PkgState -> Bool
-- | Given a FilePath to a package state file, attempt to read and
-- parse its contents. As of Aura 2.0, only state files in JSON format
-- are accepted.
readState :: Path Absolute -> IO (Maybe PkgState)
-- | The default location of all saved states: /var/cache/aura/states
stateCache :: Path Absolute
-- | The filepaths of every saved package state.
getStateFiles :: IO [Path Absolute]
instance Data.Aeson.Types.ToJSON.ToJSON Aura.State.PkgState
instance Data.Aeson.Types.FromJSON.FromJSON Aura.State.PkgState
-- | Handle the testing and dependency solving of official repository
-- packages.
module Aura.Packages.Repository
-- | Repository package source. We expect no matches to be found when the
-- package is actually an AUR package.
pacmanRepo :: IO Repository
-- | Parses the version number of a package from the result of a pacman
-- -Si call.
extractVersion :: Text -> Maybe Versioning
-- | Module for connecting to the AUR servers, downloading PKGBUILDs and
-- package sources.
module Aura.Packages.AUR
-- | Attempt to retrieve info about a given Set of packages from the
-- AUR.
aurLookup :: Manager -> NESet PkgName -> IO (Maybe (Set PkgName, Set Buildable))
-- | Yield fully realized Packages from the AUR.
aurRepo :: IO Repository
-- | Frontend to the aur library. For -Ai.
aurInfo :: NonEmpty PkgName -> RIO Env [AurInfo]
-- | Frontend to the aur library. For -As.
aurSearch :: Text -> RIO Env [AurInfo]
-- | Attempt to clone a package source from the AUR.
clone :: Buildable -> IO (Maybe (Path Absolute))
-- | A package's home URL on the AUR.
pkgUrl :: PkgName -> Text
-- | Library for handling package dependencies and version conflicts.
module Aura.Dependencies
-- | Given some Packages, determine its full dependency graph. The
-- graph is collapsed into layers of packages which are not
-- interdependent, and thus can be built and installed as a group.
--
-- Deeper layers of the result list (generally) depend on the previous
-- layers.
resolveDeps :: Repository -> NESet Package -> RIO Env (NonEmpty (NESet Package))
instance GHC.Generics.Generic Aura.Dependencies.Resolution
-- | Handle all -O flags - those which involve orphan packages.
module Aura.Commands.O
-- | Print the result of pacman -Qqdt
displayOrphans :: IO ()
-- | Identical to -D --asexplicit.
adoptPkg :: NESet PkgName -> RIO Env ()
-- | Handle all -L flags - those which involve the pacman log
-- file.
module Aura.Commands.L
-- | Pipes the pacman log file through a less session.
viewLogFile :: RIO Env ()
-- | Print all lines in the log file which contain a given Text.
searchLogFile :: Settings -> Text -> IO ()
-- | The result of -Li.
logInfoOnPkg :: NESet PkgName -> RIO Env ()
-- | Handle all -C flags - those which involve the package cache.
module Aura.Commands.C
-- | Interactive. Gives the user a choice as to exactly what versions they
-- want to downgrade to.
downgradePackages :: NESet PkgName -> RIO Env ()
-- | Print all package filenames that match a given Text.
searchCache :: Text -> RIO Env ()
-- | The destination folder must already exist for the back-up to begin.
backupCache :: Path Absolute -> RIO Env ()
-- | Keeps a certain number of package files in the cache according to a
-- number provided by the user. The rest are deleted.
cleanCache :: Word -> RIO Env ()
-- | Only package files with a version not in any PkgState will be removed.
cleanNotSaved :: RIO Env ()
-- | Handle all -B flags - those which involve saved package
-- states.
module Aura.Commands.B
-- | Save a package state. In writing the first state file, the
-- states directory is created automatically.
saveState :: Settings -> IO ()
-- | Does its best to restore a state chosen by the user.
restoreState :: RIO Env ()
-- | Remove all but the newest n package states. Any "pinned"
-- states will also remain.
cleanStates :: Settings -> Word -> IO ()
-- | The result of -Bl.
listStates :: IO ()
-- | Agnostically builds packages, regardless of original source.
module Aura.Build
-- | Expects files like: /var/cache/pacman/pkg/*.pkg.tar.xz
installPkgFiles :: NESet PackagePath -> RIO Env ()
-- | All building occurs within temp directories, or in a location
-- specified by the user with flags.
buildPackages :: NESet Buildable -> RIO Env (NESet PackagePath)
-- | Layer for AUR package installation. Backend for A.
module Aura.Install
-- | High level install command. Handles installing dependencies.
install :: NESet PkgName -> RIO Env ()
-- | Display dependencies. The result of -Ad.
displayPkgDeps :: NESet PkgName -> RIO Env ()
-- | Handle all -A flags - those which involve viewing and
-- building packages from the AUR.
module Aura.Commands.A
-- | High level install command. Handles installing dependencies.
install :: NESet PkgName -> RIO Env ()
-- | The result of -Au.
upgradeAURPkgs :: Set PkgName -> RIO Env ()
-- | The result of -Ai.
aurPkgInfo :: NESet PkgName -> RIO Env ()
-- | The result of -As.
aurPkgSearch :: Text -> RIO Env ()
-- | Display dependencies. The result of -Ad.
displayPkgDeps :: NESet PkgName -> RIO Env ()
-- | The result of -Ap.
displayPkgbuild :: NESet PkgName -> RIO Env ()
-- | Similar to -Ai, but yields the raw data as JSON instead.
aurJson :: NESet PkgName -> RIO Env ()