浏览代码

pythonlib: fix adding .py extension on windows

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@57183 15284696-431f-4ddb-bdfa-cd5b030d7da7
Anna Petrášová 11 年之前
父节点
当前提交
46909b37bb
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lib/python/script/task.py

+ 1 - 1
lib/python/script/task.py

@@ -448,7 +448,7 @@ def get_interface_description(cmd):
         
         # TODO: replace ugly hack bellow
         if not cmdout and sys.platform == 'win32':
-            if os.path.splitext(cmd)[1] == '':
+            if os.path.splitext(cmd)[1] != '.py':
                 cmd += '.py'
             
             os.chdir(os.path.join(os.getenv('GISBASE'), 'scripts'))