On Tue, Jan 10, 2012 at 11:42 PM, <gra...@percival-music.ca> wrote: > > http://codereview.appspot.com/5530069/diff/1/python/book_latex.py > File python/book_latex.py (right): > > http://codereview.appspot.com/5530069/diff/1/python/book_latex.py#newcode274 > python/book_latex.py:274: rep['base'] = basename.replace ('\\', '/') > hmm, isn't there anything in os.path that could handle this > automagically for us? I get nervous when I see explicit '/' in path > names in python. > > http://codereview.appspot.com/5530069/
Here rep is a dictionary used for string replacement in the output, and I only modify it for latex output, so I think it's pretty safe. We could add checks for os.path.sep == '\\' and os.path.altsep == '/', but otherwise I don't know of any os.path functions to replace path separators. _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-devel