comparison bin/publishdebianpackages.py @ 430:4aaf73a6225e treepkg-status

introduced after_copy_hook and made rsync upload to publishdir optional
author Bjoern Ricks <bricks@intevation.de>
date Thu, 29 Jul 2010 12:07:57 +0000
parents 9cfa9f64387a
children 0953704dc49e
comparison
equal deleted inserted replaced
429:9cfa9f64387a 430:4aaf73a6225e
30 config_desc = ["distribution", "section", "num_newest", 30 config_desc = ["distribution", "section", "num_newest",
31 "build_user", "build_host", "build_listpackages", 31 "build_user", "build_host", "build_listpackages",
32 "publish_user", "publish_host", 32 "publish_user", "publish_host",
33 ("architectures", shlex.split, "armel i386 source"), 33 ("architectures", shlex.split, "armel i386 source"),
34 ("after_upload_hook", shlex.split), 34 ("after_upload_hook", shlex.split),
35 ("after_copy_hook", shlex.split),
36 ("publish_packages", convert_bool, "False"),
35 ("publish_remove_old_packages", convert_bool), 37 ("publish_remove_old_packages", convert_bool),
36 ("publish_dir", remove_trailing_slashes), 38 ("publish_dir", remove_trailing_slashes),
37 ("cachedb", 39 ("cachedb",
38 lambda s: expand_filename(remove_trailing_slashes(s))), 40 lambda s: expand_filename(remove_trailing_slashes(s))),
39 ("cachedir", 41 ("cachedir",
226 if section is None: 228 if section is None:
227 section = config["section"] 229 section = config["section"]
228 230
229 architectures = config["architectures"] 231 architectures = config["architectures"]
230 copy_to_cachedir(config, track, revision, quiet, architectures) 232 copy_to_cachedir(config, track, revision, quiet, architectures)
231 for arch in architectures: 233
232 copy_arch_to_publishdir(config, dist, section, get_binary_arch(arch), 234 if config["after_copy_hook"] and \
233 quiet) 235 len((config["after_copy_hook"][0]).strip()) > 0:
236 if not quiet:
237 print "running after copy hook"
238 call(config["after_copy_hook"])
239
240 if config["publish_packages"]:
241 for arch in architectures:
242 copy_arch_to_publishdir(config, dist, section, get_binary_arch(arch),
243 quiet)
234 244
235 # update apt archive 245 # update apt archive
236 if config["after_upload_hook"] and \ 246 if config["after_upload_hook"] and \
237 len((config["after_upload_hook"][0]).strip()) > 0: 247 len((config["after_upload_hook"][0]).strip()) > 0:
238 if not quiet: 248 if not quiet:
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)