Skip to content

Commit

Permalink
Merge pull request #453 from madig/fix-output-dir-exist-check
Browse files Browse the repository at this point in the history
Set output directory to "." if script launched in current dir and nothing is specified

Prevents crash in glyphsLib/__init__.py#L112 when glyphs2ufo is launched from same directory as .glyphs file.
  • Loading branch information
madig authored Oct 31, 2018
2 parents cfef8fb + 39a9a8f commit 477f9b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Lib/glyphsLib/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ def main(args=None):
def glyphs2ufo(options):
"""Converts a Glyphs.app source file into UFO masters and a designspace file."""
if options.output_dir is None:
options.output_dir = os.path.dirname(options.glyphs_file)
options.output_dir = os.path.dirname(options.glyphs_file) or "."

if options.designspace_path is None:
options.designspace_path = os.path.join(
Expand Down

0 comments on commit 477f9b8

Please sign in to comment.