select-rpms-0.2.0: Select a subset of RPM packages
Safe HaskellSafe-Inferred
LanguageHaskell2010

SelectRPMs

Synopsis

Documentation

data Select Source #

The Select type specifies the subpackage selection

Constructors

All

all packages

Ask

interactive prompting

PkgsReq 

Fields

Instances

Instances details
Eq Select Source # 
Instance details

Defined in SelectRPMs

Methods

(==) :: Select -> Select -> Bool #

(/=) :: Select -> Select -> Bool #

selectDefault :: Select Source #

default package selection

selectRpmsOptions :: Parser Select Source #

optparse-applicative Parser for Select

installArgs :: String -> Select Source #

alternative CLI args option parsing to Select packages

checkSelection :: Monad m => Select -> m () Source #

check package Select is not empty

rpmsToNVRAs :: [String] -> [NVRA] Source #

converts a list of RPM files to NVRA's, filtering out debug subpackages

data Existence Source #

current state of a package NVR

Constructors

ExistingNVR

NVR is already installed

ChangedNVR

NVR is different to installed package

NotInstalled

package is not currently installed

Instances

Instances details
Show Existence Source # 
Instance details

Defined in SelectRPMs

Eq Existence Source # 
Instance details

Defined in SelectRPMs

Ord Existence Source # 
Instance details

Defined in SelectRPMs

type ExistNVRA = (Existence, NVRA) Source #

combines Existence state with an NVRA

data Yes Source #

sets prompt default behaviour for yes/no questions

Constructors

No 
Yes 

Instances

Instances details
Eq Yes Source # 
Instance details

Defined in SelectRPMs

Methods

(==) :: Yes -> Yes -> Bool #

(/=) :: Yes -> Yes -> Bool #

data ExistingStrategy Source #

how to handle already installed packages: re-install, skip, or default update

The default strategy is to select existing subpackages, otherwise all.

Instances

Instances details
Eq ExistingStrategy Source # 
Instance details

Defined in SelectRPMs

decideRPMs Source #

Arguments

:: Yes

prompt default choice

-> Bool

enable list mode which just display the package list

-> Maybe ExistingStrategy

optional existing install strategy

-> Select

specifies package Select choices

-> String

package set prefix: allows abbreviated Select

-> [NVRA]

list of packages to select from

-> IO [ExistNVRA]

returns list of selected packages

decide list of NVRs based on a Select selection (using a package prefix)

nvraToRPM :: NVRA -> FilePath Source #

render a NVRA as rpm file

groupOnArch Source #

Arguments

:: FilePath

prefix directory (eg RPMS)

-> [ExistNVRA] 
-> [(FilePath, [ExistNVRA])] 

group rpms by arch (subdirs)

data PkgMgr Source #

package manager

Constructors

DNF3 
DNF5 
RPM 
OSTREE 

Instances

Instances details
Eq PkgMgr Source # 
Instance details

Defined in SelectRPMs

Methods

(==) :: PkgMgr -> PkgMgr -> Bool #

(/=) :: PkgMgr -> PkgMgr -> Bool #

installRPMs Source #

Arguments

:: Bool

dry-run

-> Bool

debug output

-> Maybe PkgMgr

optional specify package manager

-> Yes

prompt default choice

-> [(FilePath, [ExistNVRA])]

list of rpms to install with path

-> IO () 

do installation of packages