I installed 1.4.2 on Mac OS via macports.
However, I cannot seem to make commands.archive() work for 'files' mode,
whereas the command 'hg archive' and archival.archive() both work fine.
It's just that these lines of code from commands.py (lines 171-179) seem
very puzzling:
prefix = opts.get('prefix') # This could very well be None
if dest == '-': # Not relevant for 'files' mode
# ...deleted...
# prefix can still be None (moreover, it *should* be none for 'files')
# Now, make_filename() will do a len(None) in a moment
prefix = cmdutil.make_filename(repo, prefix, node)
# So we don't get here
archival.archive(repo, dest, node, kind, not opts.get('no_decode'),
matchfn, prefix)
Apologies if this is my mistake.
|