* (operations/build.py): Check and fail if necessary for abandoned files before creating the

*.pisi packages.
This commit is contained in:
Ozan Çağlayan
2009-08-04 13:43:33 +00:00
parent d34d845431
commit 5b79b0a9a8
2 changed files with 15 additions and 11 deletions
+3 -1
View File
@@ -1,6 +1,8 @@
2009-08-04 Ozan Çağlayan <ozan@pardus.org.tr>
* (operations/build.py): Really fix the abandoned file checking when
the path in pspec.xml and the actual path of a missed file intersects.
the path in pspec.xml and the actual path of a missed file intersects,
* (operations/build.py): Check and fail if necessary for abandoned files before creating the
*.pisi packages.
2009-08-03 Fatih Aşıcı <fatih@pardus.org.tr>
* Make it possible to specify doc directory's name via destDir
+12 -10
View File
@@ -920,6 +920,16 @@ class Builder:
ctx.ui.info(_("Generating %s,") % ctx.const.metadata_xml)
self.gen_metadata_xml(package)
abandoned_files = self.get_abandoned_files()
if ctx.get_option('debug'):
if abandoned_files:
# Fail
ctx.ui.error(_('There are abandoned files under the install dir (%s):') % (install_dir))
for f in abandoned_files:
ctx.ui.info(' - %s' % (f))
raise AbandonedFilesException
# build number
if ctx.config.options.ignore_build_no or not ctx.config.values.build.buildno:
build_no = old_build_no = None
@@ -995,14 +1005,9 @@ class Builder:
self.set_state("buildpackages")
ctx.ui.info(_("Done."))
abandoned_files = self.get_abandoned_files()
#show the files those are not collected from the install dir
# Show the files those are not collected from the install dir
if ctx.get_option('debug'):
if abandoned_files:
ctx.ui.error(_('There are abandoned files under the install dir (%s):') % (install_dir))
for f in abandoned_files:
ctx.ui.info(' - %s' % (f))
else:
if not abandoned_files:
ctx.ui.info(_('All of the files under the install dir (%s) has been collected by package(s)')
% (install_dir))
@@ -1020,9 +1025,6 @@ class Builder:
os.environ.clear()
os.environ.update(ctx.config.environ)
if abandoned_files:
raise AbandonedFilesException
return self.new_packages, self.old_packages