Mercurial > hg > fetch
comparison fetch.py @ 31:60e0e932570e
fix one error but not the one i was aiming for
author | Jeff Hammel <jhammel@mozilla.com> |
---|---|
date | Tue, 15 Nov 2011 11:45:46 -0800 |
parents | 1c963875e6cd |
children | 46d5bd33311d |
comparison
equal
deleted
inserted
replaced
30:0d3c1c78ff0a | 31:60e0e932570e |
---|---|
262 for item in items: | 262 for item in items: |
263 | 263 |
264 # fix up relative paths | 264 # fix up relative paths |
265 dest = item['dest'] | 265 dest = item['dest'] |
266 if not os.path.isabs(dest): | 266 if not os.path.isabs(dest): |
267 relative_to = self.relative_to or os.path.dirname(os.path.abspath(item['manifest'])) | 267 relative_to = self.relative_to |
268 dest = os.path.join(relative_to, dest) | 268 if not relative_to: |
269 if isinstance(item['manifest'], basestring): | |
270 relative_to = os.path.dirname(os.path.abspath(item['manifest'])) | |
271 else: | |
272 relative_to = os.getcwd() | |
273 dest = os.path.normpath(os.path.join(relative_to, dest)) | |
269 | 274 |
270 # fetch the items | 275 # fetch the items |
271 self(item['url'], destination=dest, type=item['type'], **item['options']) | 276 self(item['url'], destination=dest, type=item['type'], **item['options']) |
272 | 277 |
273 | 278 |