Fix check for extension dir in setup.py

inkscape -x gives the dir but adds an new line after that.

Fixes #101
This commit is contained in:
Florian Festi 2018-11-25 23:07:25 +01:00
parent 925c6ce6dc
commit e4b85b2fc8
1 changed files with 1 additions and 1 deletions

View File

@ -19,7 +19,7 @@ class CustomBuildExtCommand(build_py):
def run(self): def run(self):
self.execute(self.buildInkscapeExt, ()) self.execute(self.buildInkscapeExt, ())
try: try:
path = check_output(["inkscape", "-x"]) path = check_output(["inkscape", "-x"]).strip()
if not os.access(path, os.W_OK): # Can we install globaly if not os.access(path, os.W_OK): # Can we install globaly
# Not tested on Windows and Mac # Not tested on Windows and Mac
path = os.path.expanduser("~/.config/inkscape/extensions") path = os.path.expanduser("~/.config/inkscape/extensions")