Thierry Vignaud > urpmi-7.27.4 > urpm::media

Download:
urpmi-7.27.4.tgz

Dependencies

Annotate this POD

CPAN RT

New  3
Open  0
View/Report Bugs
Source   Latest Release: urpmi-8.01

NAME ^

urpm::media - Media routines for urpmi

SYNOPSIS ^

DESCRIPTION ^

read_config($urpm, $nocheck)

Loads /etc/urpmi/urpmi.cfg and performs basic checks. It does not handle old format: <name> <url> [with <path_hdlist>]

write_urpmi_cfg($urpm)

Writes the urpmi.cfg file.

configure($urpm, %options)

Read urpmi.cfg file as well as necessary synthesis files.

Options :

  • root (deprecated, set directly $urpm->{root})
  • cmdline_skiplist
  • download_callback (used by _auto_update_media)
  • callback (urpmf)
  • nodepslist (for urpmq, urpmf: when we don't need the synthesis)
  • no_skiplist (urpmf)
  • synthesis (use this synthesis file, and only this synthesis file)
  • parallel
  • usedistrib (otherwise uses urpmi.cfg)
  • media
  • excludemedia
  • sortmedia
  • update
  • searchmedia
needed_extra_media($urpm)

Return 2 booleans telling whether nonfree & tainted packages are installed respectively.

add_medium($urpm, $name, $url, $with_synthesis, %options)

Add a new medium and sync the config file accordingly.

It returns the new medium's name (might be different from the requested name if index_name was specified).

Options: ignore, index_name, nolock, update, virtual, media_info_dir, mirrorlist, zeroconf, with-dir, xml-info, on_the_fly

add_distrib_media($urpm, $name, $url, %options)

Add distribution media, according to url given. Returns the list of names of added media.

Options :

  • initial_number : when adding several numbered media, start with this number
  • probe_with : force use of rpms instead of using synthesis
  • ask_media : callback to know whether each media should be added
  • only_updates : only add "update" media (used by rpmdrake)
  • mirrorlist
  • zeroconf

Other options are passed to add_medium(): ignore, nolock, virtual

reconfig_urpmi($urpm, $rfile, $medium)

Read a reconfiguration file for urpmi, and reconfigure media accordingly. $rfile is the reconfiguration file (local), $name is the media name

the format is similar to the RewriteRule of mod_rewrite, so:

   PATTERN REPLACEMENT [FLAG]

where FLAG can be L or N

example of reconfig.urpmi:

   # this is an urpmi reconfiguration file
   /cauldron /cauldron/$ARCH
update_media($urpm, %options)

Update the urpmi database w.r.t. the current configuration. Takes care of modifications, and tries some tricks to bypass the recomputation of base files.

Recognized options :

  • all : all medias are being rebuilt
  • allow_failures: whereas failing to update a medium is non fatal
  • ask_retry : function called when a download fails. if it returns true, the download is retried
  • callback : UI callback
  • forcekey : force retrieval of pubkey
  • force : try to force rebuilding base files
  • nomd5sum : don't verify MD5SUM of retrieved files
  • nopubkey : don't use rpm pubkeys
  • probe_with : probe synthesis or rpms
  • quiet : download synthesis quietly
  • wait_lock : block until lock can be acquired
clean($urpm)

Clean params and depslist computation zone.

COPYRIGHT ^

Copyright (C) 2005 MandrakeSoft SA

Copyright (C) 2005-2010 Mandriva SA

Copyright (C) 2011-2013 Mageia

syntax highlighting: