��
�[c@s�dZddkZddkZddklZddklZddklZddkZddkZddk Z ddk
Z
ddkZddkl
Z
lZlZddkZddklZd�Zd �Zd
�Zd�Zd�Zd
�Zd�Zgd�Zdfd��YZdefd��YZdefd��YZdefd��YZdd�Zd�Z d�Z!defd��YZ"de"fd��YZ#d efd!��YZ$d"efd#��YZ%d$e%fd%��YZ&d&e%fd'��YZ'd(e%fd)��YZ(d*e%fd+��YZ)d,efd-��YZ*d.efd/��YZ+d0efd1��YZ,d2efd3��YZ-d4efd5��YZ.d6efd7��YZ/d8efd9��YZ0d:efd;��YZ1d<efd=��YZ2d>efd?��YZ3d@efdA��YZ4dBefdC��YZ5dDefdE��YZ6dFefdG��YZ7dHefdI��YZ8dJefdK��YZ9dLefdM��YZ:dNefdO��YZ;dS(Ps<
Classes for subcommands of the yum command line interface.
i����N(t
logginglevels(t_(tmisc(t
utf8_widthtutf8_width_fillt
to_unicode(t
parsePackagescCs:|iidjo#|iitd��ti�ndS(sd
Verify that the program is being run by the root user.
@param base: a YumBase object.
is,You need to be root to perform this command.N(tconftuidtloggertcriticalRtclitCliError(tbase((s!/usr/share/yum-cli/yumcommands.pytcheckRootUID%scCs||i�pkxh|ii�D]S}|ip
|io9|idjo)td�}|ii|�t i
�qqWndS(Nts
You have enabled checking of packages via GPG keys. This is a good thing.
However, you do not have any GPG public keys installed. You need to download
the keys for packages you wish to install and install them.
You can do that by running the command:
rpm --import public.gpg.key
Alternatively you can specify the url to the key you would like to use
for a repository in the 'gpgkey' option in a repository section and yum
will install it for you.
For more information contact your distribution or package provider.
(tgpgKeyChecktrepostlistEnabledtgpgcheckt
repo_gpgchecktgpgkeyRR R
RR(R
trepotmsg((s!/usr/share/yum-cli/yumcommands.pytcheckGPGKey/s
$
cCsHt|�djo1|iitd�|�|i�ti�ndS(Nis(Error: Need to pass a list of pkgs to %s(tlenR R
RtusageRR(R
tbasecmdtextcmds((s!/usr/share/yum-cli/yumcommands.pytcheckPackageArgDs
cCsDt|�djo-|iitd��|i�ti�ndS(NisError: Need an item to match(RR R
RRRR(R
RR((s!/usr/share/yum-cli/yumcommands.pytcheckItemArgKs
cCsDt|�djo-|iitd��|i�ti�ndS(Nis%Error: Need a group or list of groups(RR R
RRRR(R
RR((s!/usr/share/yum-cli/yumcommands.pyt
checkGroupArgQs
cCs�d
}t|�d jo0|iitd
�di|��ti�nxL|D]D}||jo1|iitd�|�|i�ti�qPqPWdS(Ntheaderstpackagestmetadatatdbcachetpluginssexpire-cachetrpmdbtallis#Error: clean requires an option: %ss, s!Error: invalid clean argument: %r(R R!R"R#R$sexpire-cachesrpmdbsall(RR R
RtjoinRRR(R
RRt
VALID_ARGStcmd((s!/usr/share/yum-cli/yumcommands.pyt
checkCleanArgWs
cCs�t|�djo|iitd��n�t|�djol|iitd�|d�tii|d�p4|iitd�|d�|i �t
i�q�n*|iitd��|i �t
i�dS(s�
Verify that the arguments given to 'yum shell' are valid.
yum shell can be given either no args, or exactly one argument,
which is the name of a file. If these are not met,
raise cli.CliError.
isNo argument to shellisFilename passed to shell: %ss2File %s given as argument to shell does not exist.s5Error: more than one file given as argument to shell.N(Rtverbose_loggertdebugRtostpathtisfileR R
RRR(R
RR((s!/usr/share/yum-cli/yumcommands.pyt
checkShellArgfs
cCs�todS|ii�odSx6|D].}|id�otii|�odSq(Wtd�}|ii |�t
i�dS(s]
Verify that there is at least one enabled repo.
@param base: a YumBase object.
Ns.rpms�There are no enabled repos.
Run "yum repolist all" to see the repos you have.
You can enable repos with yum-config-manager --enable <repo>(tTrueRRtendswithR-R.texistsRR R
RR(R
tpossible_local_filestlfileR((s!/usr/share/yum-cli/yumcommands.pytcheckEnabledRepos # t
YumCommandcBsPeZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z RS(cCst|_t|_dS(N(tFalsetdone_command_oncethidden(tself((s!/usr/share/yum-cli/yumcommands.pyt__init__�s cGs4|ip|iiti||�nt|_dS(N(R9R+tlogRtINFO_2R1(R;R
Rtargs((s!/usr/share/yum-cli/yumcommands.pytdoneCommand�s
cCsgS(N((R;((s!/usr/share/yum-cli/yumcommands.pytgetNames�scCs
t�dS(sO
@return: A usage string for the command, including arguments.
N(tNotImplementedError(R;((s!/usr/share/yum-cli/yumcommands.pytgetUsage�scCs
t�dS(sG
@return: A one line summary of what the command does.
N(RB(R;((s!/usr/share/yum-cli/yumcommands.pyt
getSummary�scCsdS(N((R;R
RR((s!/usr/share/yum-cli/yumcommands.pytdoCheck�scCsdtd�gfS(s�
@return: (exit_code, [ errors ]) where exit_code is:
0 = we're done, exit
1 = we've errored, exit with error string
2 = we've got work yet to do, onto the next stage
is
Nothing to do(R(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyt doCommand�scCstS(N(R1(R;R
RR((s!/usr/share/yum-cli/yumcommands.pytneedTs�s(
t__name__t
__module__R<R@RARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR7�s tInstallCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Ntinstall((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCs
td�S(Ns
PACKAGE...(R(R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns,Install a package or packages on your system(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs5t|�t|�t|||�t||�dS(N(RRRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsY|i|td��y|i|�SWn+tiij
o}dt|�gfSXdS(NsSetting up Install Processi(R@RtinstallPkgstyumtErrorstYumBaseErrortstr(R;R
RRte((s!/usr/share/yum-cli/yumcommands.pyRF�s
(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyRJ�s
t
UpdateCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Ntupdates update-to((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCs
td�S(Ns[PACKAGE...](R(R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns+Update a package or packages on your system(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs%t|�t|�t||�dS(N(RRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCse|i|td��y|i|d|dj�SWn+tiij
o}dt|�gfSXdS(NsSetting up Update Processt update_tos update-toi(R@Rt
updatePkgsRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s
(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyRR�s
tDistroSyncCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Nsdistribution-synchronizationsdistro-sync((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCs
td�S(Ns[PACKAGE...](R(R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns?Synchronize installed packages to the latest available versions(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs%t|�t|�t||�dS(N(RRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCse|i|td��yd|i_|i|�SWn+tiij
o}dt|�gfSXdS(Ns/Setting up Distribution Synchronization Processi( R@RRt obsoletestdistroSyncPkgsRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyRV�s
RcCs�t|i�dt|i�t|�}t|i�dt|i�}t|i�}|idjo|t|i�d7}nxWd|fd|fd|ffD]4\}}||i|d�|||cd7<q�WdS(sl Get the length of each pkg's column. Add that to data.
This "knows" about simpleList and printVer. it0tnatvertridiN(Rtnametarchtversiontreleasetui_from_repotepocht
setdefault(tdatatpkgtindentRZR[R\tdtv((s!/usr/share/yum-cli/yumcommands.pyt_add_pkg_simple_list_lenss* "c Cshhd6hd6hd6}xJ|i|i|i|i|ifD]$}x|D]}t||�qMWq@Wt|i�djo>x;|iD],\}}t||�t||dd�q�Wn|d|d|dg}|i |dd �}|d|d |d
fS(sA Work out the dynamic size of the columns to pass to fmtColumns. RZR[R\iRft itremainder_columniis (
t installedt availabletextrastupdatestrecentRiRRWtobsoletesTuplestcalcColumns(R
typlRdtlstRetnpkgtopkgtcolumns((s!/usr/share/yum-cli/yumcommands.pyt_list_cmd_calc_columnss
cCsd|p|St||�\}}}t||�}g}|D]}||jo||q?q?~S(sE Do an extra exclude for installed packages that match the cmd line. (Rtset(tpkgstcmdline_excludesRQtmtutexcludedt_[1]tpo((s!/usr/share/yum-cli/yumcommands.pyt_cmdline_exclude s
tInfoCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Ntinfo((R;((s!/usr/share/yum-cli/yumcommands.pyRA)scCsdS(Ns7[PACKAGE|all|installed|updates|extras|obsoletes|recent]((R;((s!/usr/share/yum-cli/yumcommands.pyRC,scCs
td�S(Ns4Display details about a package or group of packages(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD/scCs�y)|iid}|i|d|�}Wn+tiij
o}dt|�gfSXh}h}h} d}
|djot||�}
n|oq|i ogxd|i
|i|iD]G}|i
|if}||jp|i||�o|||<q�q�Wn|oc|ioYxV|iD]G}|i
|if}||jp|i||�o|||<q"q"Wn|ob|ioXxUt|i�D]@}
|
iidjo'|
i�o|
| |
i
|
if<q�q�Wn|ii}|ii}|ii}|ii}|iiot|i |i�|_ n|i|i t d�|d|d|
d h|d
6|d6|d6|d
6�}|ii!}|ii"}|ii#}|ii$}|i|it d�|d|d|
d h|d6|d
6|d6|d
6�}|i|i%t d�|d|
�}|ii&}|ii'}|i|it d�|d| d|
d h|d6|d
6�}t(|i)�djog|djoZddg}t d�GHxdt|i*dt+i,d��D]}|i-|dd|
�q�Wn%|i|i)t d�|d|
�}|i|i.t d�|d|
�}t(|�oV|doK|do@|do5|do*|do|dodt d�gfSdgfSdS(Ntboldtinstalled_availableitlistRlsInstalled Packagesthighlight_naRwthighlight_modest>t<t=snot insAvailable PackagessExtra PackagessUpdated PackagesiRsObsoleting PackagestkeyRWsRecently Added PackagessNo matching Packages to list(/ttermtMODEtreturnPkgListsRMRNRORPtNoneRxRlthidden_availabletreinstall_availablet
old_availableR]R^tverGTRmthidden_installedRotsortedRtidtverifyLocalPkgRtcolor_list_installed_oldertcolor_list_installed_newertcolor_list_installed_reinstalltcolor_list_installed_extratquery_install_excludesR�R{tlistPkgsRtcolor_list_available_upgradetcolor_list_available_downgradetcolor_list_available_reinstalltcolor_list_available_installRntcolor_update_localtcolor_update_remoteRRWRqtoperatort
itemgettertupdatesObsoletesListRp(R;R
RRt highlightRsRQtupdate_pkgst inst_pkgst
local_pkgsRwReR�R�tcliotclintclirtclietriptclautcladtclartclaitraptreptcultcurtruptroptobtuptrrap((s!/usr/share/yum-cli/yumcommands.pyRF2s�
!
! "
#
BcCs't|�o|ddjotStS(NiRl(RR8R1(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG�s(RHRIRARCRDRFRG(((s!/usr/share/yum-cli/yumcommands.pyR�(s
]tListCommandcBseZd�Zd�ZRS(cCsdgS(NR�((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCs
td�S(Ns$List a package or groups of packages(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�s(RHRIRARD(((s!/usr/share/yum-cli/yumcommands.pyR��s tEraseCommandcBsGeZd�Zd�Zd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Nterasetremove((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(Ns
PACKAGE...((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns-Remove a package or packages from your system(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCst|�t|||�dS(N(RR(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsY|i|td��y|i|�SWn+tiij
o}dt|�gfSXdS(NsSetting up Remove Processi(R@Rt erasePkgsRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG�scCstS(N(R1(R;R
RR((s!/usr/share/yum-cli/yumcommands.pytneedTsRemove�s( RHRIRARCRDRERFRGR�(((s!/usr/share/yum-cli/yumcommands.pyR��s tGroupCommandcBseZd�ZRS(cCs�|i|td��|idd�y|i�WnStiij
odtd�gfStiij
o}dt|�gfSXdS(NsSetting up Group Processtdosackiis!No Groups on which to run command( R@RtdoRepoSetuptdoGroupSetupRMRNtGroupsErrorRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s(RHRIRF(((s!/usr/share/yum-cli/yumcommands.pyR��stGroupListCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Nt grouplist((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(NR((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(NsList available package groups(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCst|�dS(N(R6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�scCs#ti||||�|i|�S(N(R�RFtreturnGroupLists(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRF�scCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG�s(RHRIRARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR��s tGroupInstallCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Ntgroupinstalltgroupupdate((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(NsGROUP...((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns.Install the packages in a group on your system(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs2t|�t|�t|||�t|�dS(N(RRRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsYti||||�y|i|�SWn+tiij
o}dt|�gfSXdS(Ni(R�RFt
installGroupsRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s
(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyR��s
tGroupRemoveCommandcBsGeZd�Zd�Zd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Ntgroupremovet
grouperase((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(NsGROUP...((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns/Remove the packages in a group from your system(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs(t|�t|||�t|�dS(N(RRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsYti||||�y|i|�SWn+tiij
o}dt|�gfSXdS(Ni(R�RFtremoveGroupsRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRFs
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRGscCstS(N(R1(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyR�
s( RHRIRARCRDRERFRGR�(((s!/usr/share/yum-cli/yumcommands.pyR��s tGroupInfoCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Nt groupinfo((R;((s!/usr/share/yum-cli/yumcommands.pyRAscCsdS(NsGROUP...((R;((s!/usr/share/yum-cli/yumcommands.pyRCscCs
td�S(Ns%Display details about a package group(R(R;((s!/usr/share/yum-cli/yumcommands.pyRDscCst|||�t|�dS(N(RR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyREscCsYti||||�y|i|�SWn+tiij
o}dt|�gfSXdS(Ni(R�RFtreturnGroupInfoRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRFs
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG"s(RHRIRARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR�
s tMakeCacheCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Nt makecache((R;((s!/usr/share/yum-cli/yumcommands.pyRA'scCsdS(NR((R;((s!/usr/share/yum-cli/yumcommands.pyRC*scCs
td�S(NsGenerate the metadata cache(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD-scCst|�dS(N(R6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE0scCs_|iitd��|iitd��y�x,|iid�D]}d|_d|_qBW|idd�|ii�|ii ddd d
�hdd6d
d6dd6}xk|ii
�D]Z}xQ|ii�D]@}||joq�nt
i|i|�||d|i�q�Wq�WWn+tiij
o}d
t|�gfSXdtd�gfS(Ns*Making cache files for all metadata files.s=This may take a while depending on the speed of this computert*is group:allR�tmdtypeR&t cacheonlyis
groups.xmltgroup_gzspkgtags.sqlitetpkgtagssupdateinfo.xmlt
updateinfotcachedsMetadata Cache Created(R R,RRt findRepostmetadata_expiretmdpolicyR�tdoSetuptpopulateSackRtrepoXMLt fileTypesRtrepo_gen_decompresst
retrieveMDtcacheRMRNRORP(R;R
RRRt fname_maptMDRQ((s!/usr/share/yum-cli/yumcommands.pyRF3s2
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRGTs(RHRIRARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR�%s !tCleanCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Ntclean((R;((s!/usr/share/yum-cli/yumcommands.pyRAYscCsdS(Ns<[headers|packages|metadata|dbcache|plugins|expire-cache|all]((R;((s!/usr/share/yum-cli/yumcommands.pyRC\scCs
td�S(NsRemove cached data(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD_scCst|||�t|�dS(N(R*R6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyREbscCsd|i_|i|�S(Ni(RR�tcleanCli(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRFfscCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRGjs(RHRIRARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR�Ws tProvidesCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Ntprovidestwhatprovides((R;((s!/usr/share/yum-cli/yumcommands.pyRAnscCsdS(NtSOME_STRING((R;((s!/usr/share/yum-cli/yumcommands.pyRCqscCs
td�S(Ns*Find what package provides the given value(R(R;((s!/usr/share/yum-cli/yumcommands.pyRDtscCst|||�dS(N(R(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyREwscCsS|iid�y|i|�SWn+tiij
o}dt|�gfSXdS(NsSearching Packages: i(R R,R�RMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRFzs
(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyR�ms
tCheckUpdateCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Nscheck-update((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(Ns[PACKAGE...]((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns#Check for available package updates(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCst|�dS(N(R6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�scCs"dg|}|iidd�d}y�|i|�}|iip|iiti�o+|i|�}|i|_|i |_ nt
||�}t|i�djo�h} |i
id}
|
oXxUt|i�D]@}|iidjo'|i�o|| |i|if<q�q�Wn|ii}|ii}
|i|idddd | d
|dh|d6|
d
6�d}nt|i�djoTtd�GHx<t|i dtid��D]}|i|dd
|�q�Wd}nWn+tiij
o}dt|�gfSX|gfSdS(NRWiRoR�RlRt
outputTypeR�R�RwR�R�snot inidsObsoleting PackagesR�i( RtinsertR�RRWR+tisEnabledForRtDEBUG_3RqRxRRoR�R�R�RR�R�R]R^R�R�R�RR�R�R�RMRNRORP(R;R
RRtobscmdstresultRsttyplRwR�R�R�R�R�R�RQ((s!/usr/share/yum-cli/yumcommands.pyRF�sH
"
(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyR��s
t
SearchCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Ntsearch((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(NR�((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns+Search package details for the given string(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCst|||�dS(N(R(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�scCsY|iitd��y|i|�SWn+tiij
o}dt|�gfSXdS(NsSearching Packages: i(R R,RR�RMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG�s(RHRIRARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR��s tUpgradeCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Ntupgrades
upgrade-to((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(Ns
PACKAGE...((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns-Update packages taking obsoletes into account(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs%t|�t|�t||�dS(N(RRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsqd|i_|i|td��y|i|d|dj�SWn+tiij
o}dt|�gfSXdS(NisSetting up Upgrade ProcessRTs
upgrade-to( RRWR@RRURMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyR��s
tLocalInstallCommandcBsGeZd�Zd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsti|�t|_dS(N(R7R<R1R:(R;((s!/usr/share/yum-cli/yumcommands.pyR<�s
cCs
ddgS(Ntlocalinstalltlocalupdate((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(NtFILE((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(NsInstall a local RPM(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs(t|�t|�t|||�dS(N(RRR(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsn|i|td��|dj}y|id|d|�SWn+tiij
o}dt|�gfSXdS(Ns Setting up Local Package ProcessRtfilelistt
updateonlyi(R@RtlocalInstallRMRNRORP(R;R
RRRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�scCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRGs( RHRIR<RARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR��s tResolveDepCommandcBs,eZd�Zd�Zd�Zd�ZRS(cCsdgS(Nt
resolvedep((R;((s!/usr/share/yum-cli/yumcommands.pyRAscCsdS(Nt
DEPENDENCY((R;((s!/usr/share/yum-cli/yumcommands.pyRCscCs
td�S(Ns5Determine which package provides the given dependency(R(R;((s!/usr/share/yum-cli/yumcommands.pyRDscCsY|iitd��y|i|�SWn+tiij
o}dt|�gfSXdS(Ns"Searching Packages for Dependency:i(R R,Rt
resolveDepCliRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRFs
(RHRIRARCRDRF(((s!/usr/share/yum-cli/yumcommands.pyRs tShellCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Ntshell((R;((s!/usr/share/yum-cli/yumcommands.pyRAscCsdS(Ns
[FILENAME]((R;((s!/usr/share/yum-cli/yumcommands.pyRCscCs
td�S(NsRun an interactive yum shell(R(R;((s!/usr/share/yum-cli/yumcommands.pyRDscCst|||�dS(N(R0(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyREscCsV|i|td��y|i�SWn+tiij
o}dt|�gfSXdS(NsSetting up Yum Shelli(R@RtdoShellRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF"s
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG)s(RHRIRARCRDRERFRG(((s!/usr/share/yum-cli/yumcommands.pyR s tDepListCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Ntdeplist((R;((s!/usr/share/yum-cli/yumcommands.pyRA.scCsdS(Ns
PACKAGE...((R;((s!/usr/share/yum-cli/yumcommands.pyRC1scCs
td�S(NsList a package's dependencies(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD4scCst|||�dS(N(R(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE7scCsY|i|td��y|i|�SWn+tiij
o}dt|�gfSXdS(NsFinding dependencies: i(R@RR
RMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF:s
(RHRIRARCRDRERF(((s!/usr/share/yum-cli/yumcommands.pyR-s
tRepoListCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCsdS(Ntrepolist(R((R;((s!/usr/share/yum-cli/yumcommands.pyRADscCsdS(Ns[all|enabled|disabled]((R;((s!/usr/share/yum-cli/yumcommands.pyRCGscCs
td�S(Ns,Display the configured software repositories(R(R;((s!/usr/share/yum-cli/yumcommands.pyRDJsc2s
�fd�}�fd�}d�}t|�djo)|dd:jo|d}|d}nd}td �|�}�iiti�}|djp|o�y�ii��iWq7t i
ij
ob|o�nxO�ii�D]9} y�ii| i
�Wq�t i
ij
oq�Xq�Wq7Xn�iii�}
|
i��ii�}�iid
�iid}�iid}
�iid
}d}g}xM|
D]E} t|�o|| |�oq�nd;\}}}d}d}d}d}t}|djp | i
|jp| i|jot}||
|}}}n| |jo�t}|djo
t}n|djo|oq�n|p|oI|td�|}ttd��}|p|d7}|d7}q�n|o|| �}n|djp|o�|p�iip
| iot| ii��}nt| i�}||�}| ii}tg}|D]$\}}|| jo||q�q�~�}|o)||�}|p|d|7}q�n||7}q[n`t}|djo
t}n|djo|oq�n|td�|}ttd��}to�|pwt| �} |o>| io4| ii i!}!|!| i"i!jod| } q�n|i#| | i||f|f�q� |o
| i"}"nd}"�i%td�| ��i%td�| i�g}#|p|o#|#�i%td�|�g7}#n|"o6|"i&dj o&|#�i%td�|"i&�g7}#n|"oM|"i'do?|"i'd}$|#�i%td�di(t)|$���g7}#n|"oy|"i'dokxht)|"i'd�D]O}%|"i'd|%}$|#�i%td�d|%di(t)|$��f�g7}#qWn|"oY|#�i%td�t*i+|"i!���i%td�|��i%td�|�g7}#nt,| d �o
| i-}&n
| i.}&|&o,|#�i%td!�di(|&��g7}#n|o| i/n| ioh|#�i%td"�| i�g7}#|o;| ii i!}'|#�i%td#�t*i+|'��g7}#q�n1| i0o&|#�i%td$�| i0�g7}#n|ow| i/om|&oe| i/d}(t| i/�djo|(d%t| i/�d7}(n|#�i%td!�|(�g7}#nt1i2i3| i4�ptd&�})n%t1i5| i4�i6})t*i+|)�})| i7d'jotd(�|)}nD| i7ptd)�|)}n&|| i7�}td*�||)f}|#�i%td+�|�g7}#| io/|#�i%td,�di(| i��g7}#n| i8o/|#�i%td-�di(| i8��g7}#n|o#|#�i%td.�|�g7}#n�ii9tid/d0i(tt:i;|#���q�q�W|o�|o�ttd1��}*d}+d},d}-x�|D]�\} }.\}}}|*t| �jot| �}*n|+t|.�jot|.�}+n|,|t|�jo|t|�},n|-t|�jot|�}-q6
q6
W|djo�ii<|*d}/nZttd2��|,jo(�ii<|*ttd2��d}/n�ii<|*|,d}/|/|+jo
|/}+n+|/|+8}/|*|/d7}*|+|/|/d7}+t=td1�|*�}0t=td3�|+|+�}1|djo �ii9ti>d4|0|1�n&�ii9ti>d5|0|1td2��x�|D]�\} }.\}}}|djo8�ii9ti>d4t=| |*�t=|.|+|+��q+n|ot=||-d6t�}n�ii9ti>d7t=| |*�t=|.|+|+�||�q+Wndd8t;t?i@d9|t��gfS(<Ncs:d}x$|ii�D]}||i7}qW�i|�S(Ni(tsacktreturnPackagestpackagesizet
format_number(RtretRe(R
(s!/usr/share/yum-cli/yumcommands.pyt
_repo_sizeNs
cs?x8|D]0}|�ii|dtdt�jotSqWtS(Nt
name_matchtignore_case(RR�R1R8(Rtpatternstpat(R
(s!/usr/share/yum-cli/yumcommands.pyt_repo_matchTs
cSsttid|t��S(Ns%d(RtlocaletformatR1(tnum((s!/usr/share/yum-cli/yumcommands.pyt_num2ui_num[siiR&tdisabledtenabledcSs
|i�S((tlower(tx((s!/usr/share/yum-cli/yumcommands.pyt<lambda>cstgreenR�tredtnormalRs: is+%sR�sRepo-id : sRepo-name : sRepo-status : sRepo-revision: tcontentsRepo-tags : s, tdistrosRepo-distro-tags: s[%s]: %ssRepo-updated : sRepo-pkgs : sRepo-size : t
_orig_baseurlsRepo-baseurl : sRepo-metalink: s Updated : sRepo-mirrors : s
(%d more)tUnknowni����sNever (last: %s)sInstant (last: %s)s%s second(s) (last: %s)sRepo-expire : sRepo-exclude : sRepo-include : sRepo-excluded: s%s
s
srepo idtstatuss repo names%s %ss%s %s %stlefts
%s %s %s%ss
repolist: s%d(sallRsenabled(RRR(ARtmapR+R�RR�RR�tpkgSackRMRNt RepoErrorRR�tvaluestsortR�tFG_COLORR�R8R]R1RRRtexcludeRt
simplePkgListt _excludesRPtmetalinkt
metalink_datatrepomdt timestampR�tappendR�t
fmtKeyValFilltrevisionttagsR'R�ttimetctimethasattrR)tbaseurlturlst
mirrorlistR-R.R3tmetadata_cookietstattst_mtimeR�tincludepkgsR=RRRwRR>RR(2R;R
RRRRRtargtverboseRRt
enabled_repost on_ehibegt on_dhibegton_hiendttot_numtcolstehibegtdhibegthiendt
ui_enabledtui_endis_widtui_numtui_excludes_numt
force_showR tui_sizeRtexcludesRtrtpidR\tmdtstmdtoutR=R(tbaseurlsttsturltlasttid_lentnm_lentst_lentui_lentrnameR,ttxt_ridttxt_rnam((R
s!/usr/share/yum-cli/yumcommands.pyRFMs� $
-
>
(
$
(
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRGNs(RHRIRARCRDRFRG(((s!/usr/share/yum-cli/yumcommands.pyRBs �tHelpCommandcBsMeZd�Zd�Zd�Zd�Zed��Zd�Zd�Z RS(cCsdgS(Nthelp((R;((s!/usr/share/yum-cli/yumcommands.pyRATscCsdS(NtCOMMAND((R;((s!/usr/share/yum-cli/yumcommands.pyRCWscCs
td�S(NsDisplay a helpful usage message(R(R;((s!/usr/share/yum-cli/yumcommands.pyRDZscCslt|�djo|i�ti�n?t|�djp|d|ijo|i�ti�ndS(Nii(RRRRtyum_cli_commands(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE]s
'
c
Csg|i�d}y|i�}Wnttfj
o
d}nXy|i�}Wnttfj
o
d}nXd}|dj o|d||f7}n|dj o|d|7}n|djo!|djotd�|}n|i�}t|�djoXt|�djo|td�7}n|td �7}|d
i|i�d�7}n|S(NiRs%s %ss
%ssNo help available for %siis
aliases: s
alias: s, ( RARCtAttributeErrorRBR�RDRRR'(tcommandtcanonical_nameRtsummarythelp_outputt
command_names((s!/usr/share/yum-cli/yumcommands.pyt_makeOutputes.
!cCsR|d|ijo4|i|d}|iiti|i|��ndgfS(Ni(RmR+R=RR>Rt(R;R
RRRo((s!/usr/share/yum-cli/yumcommands.pyRF�s
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG�s(
RHRIRARCRDREtstaticmethodRtRFRG(((s!/usr/share/yum-cli/yumcommands.pyRjRs $ tReInstallCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Nt reinstall((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(Ns
PACKAGE...((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs5t|�t|�t|||�t||�dS(N(RRRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsY|i|td��y|i|�SWn+tiij
o}dt|�gfSXdS(NsSetting up Reinstall Processi(R@Rt
reinstallPkgsRMRNROR(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s
cCs
td�S(Nsreinstall a package(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG�s(RHRIRARCRERFRDRG(((s!/usr/share/yum-cli/yumcommands.pyRv�s tDowngradeCommandcBs>eZd�Zd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(Nt downgrade((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(Ns
PACKAGE...((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs5t|�t|�t|||�t||�dS(N(RRRR6(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRE�s
cCsY|i|td��y|i|�SWn+tiij
o}dt|�gfSXdS(NsSetting up Downgrade Processi(R@Rt
downgradePkgsRMRNRORP(R;R
RRRQ((s!/usr/share/yum-cli/yumcommands.pyRF�s
cCs
td�S(Nsdowngrade a package(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG�s(RHRIRARCRERFRDRG(((s!/usr/share/yum-cli/yumcommands.pyRy�s tVersionCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCsdgS(NR_((R;((s!/usr/share/yum-cli/yumcommands.pyRA�scCsdS(Ns[all|installed|available]((R;((s!/usr/share/yum-cli/yumcommands.pyRC�scCs
td�S(Ns9Display a version for the machine and/or available repos.(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD�scCs{d}|o|d}nd�}|iiti�}h}|d)jo1g}|djo
d}q�|td�}ntii�}xK|D]C} t|| i �|| <|| i
o|| i|i�q�q�W|d jo9t
d
�GHxt|�D]} dG| GHq�WddgfS|d
jox|D]�} | |djoq4nt
d�G| GHt
d�GH|p(x�t|| �D]}
dG|
GHq�Wq4hhd6hd6}|| }|i|�}
|i|||
�|d|dg}|i|�}|d|df}|i|t|
d|�q4WddgfS|iid}|iid}g}|d*jo�yw|ii|d|�}|ii�}|dj o
|i}n|dj o+|d|jo|id|dj �n|d+joE|idt
d�||ft|d�f�|||d�n|o�x�t|d�D]�}|id�o+t|�djo||djoqYn|id t
d!�|ft|d|�f�|||d"|�qYWnWqti i!j
o}dt|�gfSXn|d,jo^y,|i"i|d|�}|d-joP|idt
d%�||ft|d�f�|o|||d�q�n|o�x�t|d�D]�}|id�o+t|�djo||djoq�n|id t
d&�|ft|d|�f�|o|||d"|�q�q�WnWq�ti i!j
o}dt|�gfSXnhhd6hd'6}xq|D]i\}}xZdt|�fd't|�ffD]4\}}||i#|d�|||cd7<q�Wq�W|d|d'g}|i|�}|d|df}x%|D]}|i$t%||��GHqMWdd(gfS(.NRlicSs�x�t|�D]�}||}g}d}xYt|�D]K}|djoq6n||}|id||ft||�f�q6Wd|jo>|p|d|jo%|id|t|d�f�n|i|�q
WdS(Ns %s/%ss %s(R�R�R:RPtextend(ROt repo_datatrepoidR�tncolstlast_revtrev((s!/usr/share/yum-cli/yumcommands.pyt
_append_repos�s
+&%tnogroupssnogroups-installedsnogroups-availablesnogroups-alls nogroups-R�s Yum version groups:s sversion grouplistR�is
Group :s
Packages:tenvraR\Rwsversion groupinfot
releasevertbasearchR&sgroup-installeds group-alltgroupstwarns%s %s/%ss
Installed:isgroup-s%s %ssGroup-Installed:iRmsgroup-availables
Available:sGroup-Available:R[R_(R�snogroups-installedsnogroups-availablesnogroups-all(s installedsallsgroup-installeds group-all(sgroup-installeds group-all(s availablesallsgroup-availables group-all(sgroup-availables group-all(&R+R�RR�RRMtconfigtreadVersionGroupsConfigRytpkglisttrun_with_packagesRStrun_with_package_namesRR�t_group_names2aipkgst_calcDataPkgColumnsRrt_displayPkgsFromNamesR1RtyumvarR%t
simpleVersionthistoryRbR�tend_rpmdbversiont_rpmdb_warn_checksR:RPt
startswithRNROR.Rct
fmtColumnstzip(R;R
RRtvcmdR�RIR�tgconftgrouptpkgnameRdt pkg_namestpkg_names2pkgsRwtreltbaROtlastdbvtgrpRQR\R[RgRhtline((s!/usr/share/yum-cli/yumcommands.pyRF�s�
$!
$%%cCsSd}|o|d}n|iiti�}|djo|otS|djS( NRliR�RmR&sgroup-availables group-all(s availablesallsgroup-availables group-all(R+R�RR�R1(R;R
RRR�RI((s!/usr/share/yum-cli/yumcommands.pyRGOs(RHRIRARCRDRFRG(((s!/usr/share/yum-cli/yumcommands.pyR|�s
|tHistoryCommandcBsteZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z d�Z
d �Zd
�Zd�Z
RS(cCsdgS(NR�((R;((s!/usr/share/yum-cli/yumcommands.pyRAZscCsdS(NsC[info|list|packages-list|summary|addon-info|redo|undo|rollback|new]((R;((s!/usr/share/yum-cli/yumcommands.pyRC]scCs
td�S(Ns(Display, or use, the transaction history(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD`scCs�|i|�}|djoddgfSti|i�}d|i|fGH|i|�|i|�odd|ifgfSdS(NisFailed history redos!Repeating transaction %u, from %sisRepeating transaction %u(t_history_get_transactionR�R>R?t
beg_timestampttidthistoryInfoCmdPkgsAlteredthistory_redo(R;R
Rtoldttm((s!/usr/share/yum-cli/yumcommands.pyt
_hcmd_redocs
cCs�|i|�}|djoddgfSti|i�}d|i|fGH|i|�|i|�odd|ifgfSdS(NisFailed history undosUndoing transaction %u, from %sisUndoing transaction %u(R�R�R>R?R�R�R�thistory_undo(R;R
RR�R�((s!/usr/share/yum-cli/yumcommands.pyt
_hcmd_undoms
c
Cst}t|�djo/|ddjot}|}|id�n|i|�}|djoddgfS|ii�}|djoddgfS|i|ijoddgfSd}x�|ii t
|id|id��D]�}|oM|ip
|io9|io
d}nd}||iGHd GHdd
gfS|djot
ii|�}q�|i|�q�Wti|i�} d|i| fGH|idd
id�|iD���GH|i|�|i|�odd|ifgfSdS(Nitforceis'Failed history rollback, no transactions!Failed history rollback, no last?s"Rollback to current, nothing to dos-Transaction history is incomplete, before %u.s,Transaction history is incomplete, after %u.s5 You can use 'history rollback force', to try anyway.s#Failed history rollback, incompletes#Rollback to transaction %u, from %ss& Undoing the following transactions: s, cssx|]}t|�VqWdS(N(RP(t.0R"((s!/usr/share/yum-cli/yumcommands.pys <genexpr>�s isRollback to transaction %u(R8RR1tpopR�R�R�RbR�R�trangetaltered_lt_rpmdbtaltered_gt_rpmdbRMtYumMergedHistoryTransactiontmergeR>R?R�R;R'R�R�(
R;R
RR�R�RbtmobjR�RR�((s!/usr/share/yum-cli/yumcommands.pyt_hcmd_rollbackwsB$
*
cCs|ii�dS(N(R�t_create_db_file(R;R
R((s!/usr/share/yum-cli/yumcommands.pyt _hcmd_new�scCs�dG|iiGHti|ii�i}dGtid|t�GH|ii�}|djot
d�GdGHdS|ii�}|iid�d}t
d�G|i
GHt
d�Gti|i�GHt
d�Gti|i�GHt
d �GHt
d
�Gtid|dt�GHt
d
�Gtid|dt�GHt
d�Gtid|dt�GHt
d�Gtid|dt�GHt
d�Gtid|dt�GHt
d�Gtid|dt�GHdS(Ns
File :s
Size :s%ds
Transactions:it1s
Begin time :s
End time :s
Counts :s
NEVRAC :s%6dtnevracs
NEVRA :tnevras
NA :RZs
NEVR :tnevrs
rpm DB :R%s
yum DB :tyumdb(R�t_db_fileR-REtst_sizeRRR1RbR�Rt
_pkg_statsR�R�R>R?R�t
end_timestamp(R;R
RRttrans_Ntcountsttrans_1((s!/usr/share/yum-cli/yumcommands.pyt_hcmd_stats�s&
"""""cCs�|d}|p
d}nxvt|iid|��D]Y}|ii|dt�djoq7ndG|GdG|ii|�o dGHq7dGHq7WdS(NiRtcreatesSyncing rpm/yum DB data for:s...sDone.sFAILED.(R�R�R%RR�tpkg2pidR8t
sync_alldb(R;R
Rtipkg((s!/usr/share/yum-cli/yumcommands.pyt
_hcmd_sync�s
cCs�d}|o@|d|jo/|iitd�di|��ti�n|o)|ddjot|�t|�nM|ii ot
i|ii t
i�p#|iitd��ti�ndS( NR�R�Rqtrepeattredotundotnewtrollbacktaddons
addon-infotstatst
statisticstsynctsynchronizepkgRzspkg-lists pkgs-listtpackagespackage-listR!s
packages-listspkg-infos pkgs-infospackage-infos
packages-infois%Invalid history sub-command, use: %s.s, s(You don't have access to the history DB.(slistsinfossummarysrepeatR�R�snewR�R�s
addon-infoR�R�R�R�spkgsspkg-lists pkgs-listR�spackage-listspackagess
packages-listspkg-infos pkgs-infospackage-infos
packages-info(srepeatR�R�R�snew(
R R
RR'RRRRR�R�R-taccesstR_OK(R;R
RRtcmds((s!/usr/share/yum-cli/yumcommands.pyRE�s"
)c Cs�d}|o|d}nton�|djo|i|�}ns|djo|i|�}nS|djo|i|�}n3|djo|i|�}n|djo|i|�}n�|djo|i||�}n�|djo|i||�}n�|djo|i||�}n�|djo|i ||�}ng|d jo|i
||�}nD|d!jo|i||�}n!|d"jo|i|�}n|djodd|fgfS|S(#NR�iR�RqR�s
addon-infoReRzspkg-lists pkgs-listR�spackage-listR!s
packages-listR�R�R�R�R�R�R�R�tsynchronizespkg-infos pkgs-infospackage-infos
packages-infos
history %s(saddons
addon-info(spkgspkgsspkg-lists pkgs-listspackagespackage-listspackagess
packages-list(sredosrepeat(sstatss
statistics(ssyncR�(spkg-infos pkgs-infospackage-infos
packages-info(R8thistoryListCmdthistoryInfoCmdthistorySummaryCmdthistoryAddonInfoCmdthistoryPackageListCmdR�R�R�R�R�R�thistoryPackageInfoCmdR�(R;R
RRR�R((s!/usr/share/yum-cli/yumcommands.pyRF�sB
cCs%d}|o|d}n|djS(NR�iR�R�R�R�(srepeatsredosundosrollback((R;R
RRR�((s!/usr/share/yum-cli/yumcommands.pyRG�s(RHRIRARCRDR�R�R�R�R�R�RERFRG(((s!/usr/share/yum-cli/yumcommands.pyR�Ys
( $tCheckRpmdbCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Ntcheckscheck-rpmdb((R;((s!/usr/share/yum-cli/yumcommands.pyRAscCsdS(Ns[dependencies|duplicates|all]((R;((s!/usr/share/yum-cli/yumcommands.pyRCscCs
td�S(NsCheck for problems in the rpmdb(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD
sc Csod}|o
|}nd�}d}|id|dtd|dd��o
d }n|d
||fgfS(NR&cSst|i��GHdS(N(Rt__str__(R"((s!/usr/share/yum-cli/yumcommands.pyt_outsiR^R�tchkcmdtheadercSsdS(N(R�(R"((s!/usr/share/yum-cli/yumcommands.pyR#sis%s %s(R�R8(R;R
RRR�R�trc((s!/usr/share/yum-cli/yumcommands.pyRF
s
cCstS(N(R8(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRGs(RHRIRARCRDRFRG(((s!/usr/share/yum-cli/yumcommands.pyR�s
tLoadTransactionCommandcBs5eZd�Zd�Zd�Zd�Zd�ZRS(cCs
ddgS(Nsload-transactionsload-ts((R;((s!/usr/share/yum-cli/yumcommands.pyRAscCsdS(Ntfilename((R;((s!/usr/share/yum-cli/yumcommands.pyRC"scCs
td�S(Ns&load a saved transaction from filename(R(R;((s!/usr/share/yum-cli/yumcommands.pyRD%scCs�|p#|iitd��ti�n|d}|i|td�|�y|i|�Wn+tii j
o}dt
|�gfSXdtd�|t|ii
��fgfS(Ns$No saved transaction file specified.isloading transaction from %siis*Transaction loaded from %s with %s members(R R
RRRR@tload_tsRMRNRORRttsInfot
getMembers(R;R
RRt load_fileRQ((s!/usr/share/yum-cli/yumcommands.pyRF(s
cCstS(N(R1(R;R
RR((s!/usr/share/yum-cli/yumcommands.pyRG7s(RHRIRARCRDRFRG(((s!/usr/share/yum-cli/yumcommands.pyR�s
(<t__doc__R-RRMRRRt
yum.ErrorsR�RtfnmatchR>tyum.i18nRRRt
yum.configtyum.packagesRRRRRRR*R0R6R7RJRRRVRiRxR�R�R�R�R�R�R�R�R�R�R�R�R�R�R�R�RR RRRjRvRyR|R�R�R�(((s!/usr/share/yum-cli/yumcommands.pyt<module>sn
) m
26�A��