Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/src/sugar/activity/bundlebuilder.py
diff options
context:
space:
mode:
authorBernie Innocenti <bernie@codewiz.org>2010-05-20 06:19:14 (GMT)
committer Sascha Silbe <silbe@activitycentral.com>2011-07-24 16:21:38 (GMT)
commite7430faac9735eca60e33a5fb34f2a5a7cbe238e (patch)
tree2702fa792d97c4af346df5dc3d4f26bcac56c3f8 /src/sugar/activity/bundlebuilder.py
parent1f06030269c062abb384baf2ab7b0f4e94bfa3ea (diff)
Remove incomplete MANIFEST support
This incomplete feature contributes to confuse new activity authors and slightly complicates our bundle installation logic. The day someone finds something useful to do with the MANIFEST specification, we can revert this patch in no time. Signed-off-by: Bernie Innocenti <bernie@codewiz.org> Tested-by: Bernie Innocenti <bernie@codewiz.org> Tested-by: James Cameron <quozl@laptop.org> Tested-by: Sascha Silbe <silbe@activitycentral.com> Reviewed-by: Sascha Silbe <silbe@activitycentral.com> [rebased on git master, minor style fix] Signed-off-by: Sascha Silbe <silbe@activitycentral.com>
Diffstat (limited to 'src/sugar/activity/bundlebuilder.py')
-rw-r--r--src/sugar/activity/bundlebuilder.py48
1 files changed, 5 insertions, 43 deletions
diff --git a/src/sugar/activity/bundlebuilder.py b/src/sugar/activity/bundlebuilder.py
index 5885a35..5fd92c1 100644
--- a/src/sugar/activity/bundlebuilder.py
+++ b/src/sugar/activity/bundlebuilder.py
@@ -142,37 +142,9 @@ class Builder(object):
f.close()
def get_files(self):
- files = self.config.bundle.get_files()
-
- if not files:
- logging.error('No files found, fixing the MANIFEST.')
- self.fix_manifest()
- files = self.config.bundle.get_files()
-
- return files
-
- def check_manifest(self):
- missing_files = []
-
allfiles = list_files(self.config.source_dir,
IGNORE_DIRS, IGNORE_FILES)
- for path in allfiles:
- if path not in self.config.bundle.manifest:
- missing_files.append(path)
-
- return missing_files
-
- def fix_manifest(self):
- self.build()
-
- manifest = self.config.bundle.manifest
-
- for path in self.check_manifest():
- manifest.append(path)
-
- f = open(os.path.join(self.config.source_dir, 'MANIFEST'), 'wb')
- for line in manifest:
- f.write(line + '\n')
+ return allfiles
class Packager(object):
@@ -198,13 +170,6 @@ class XOPackager(Packager):
bundle_zip = zipfile.ZipFile(self.package_path, 'w',
zipfile.ZIP_DEFLATED)
- missing_files = self.builder.check_manifest()
- if missing_files:
- logging.warn('These files are not included in the manifest ' \
- 'and will not be present in the bundle:\n\n' +
- '\n'.join(missing_files) +
- '\n\nUse fix_manifest if you want to add them.')
-
for f in self.builder.get_files():
bundle_zip.write(os.path.join(self.config.source_dir, f),
os.path.join(self.config.bundle_root_dir, f))
@@ -311,14 +276,11 @@ def cmd_dist_xo(config, args):
def cmd_fix_manifest(config, args):
- """Add missing files to the manifest"""
+ '''Add missing files to the manifest (OBSOLETE)'''
- if args:
- print 'Usage: %prog fix_manifest'
- return
-
- builder = Builder(config)
- builder.fix_manifest()
+ print 'WARNING: The fix_manifest command is obsolete.'
+ print ' The MANIFEST file is no longer used in bundles,'
+ print ' please remove it.'
def cmd_dist_source(config, args):