Mercurial > piecrust2
view tests/pathutil.py @ 302:103abb08755e
import: Make the Wordpress importer extendable, rename it to `wordpressxml`.
This is because the SQL importer will be installable as a plugin, so as to not
impose SQL dependencies on the basic PieCrust package.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Thu, 19 Mar 2015 18:30:09 -0700 |
parents | a2d283d1033d |
children |
line wrap: on
line source
import os def slashfix(path): if path is None: return None if isinstance(path, str): return path.replace('/', os.sep) fixed = [] for p in path: fixed.append(p.replace('/', os.sep)) return fixed