mirror of
https://gitlab.com/openlp/packaging.git
synced 2024-12-22 13:02:50 +00:00
Absolute paths
This commit is contained in:
parent
5ce4f143fa
commit
6e6f6ddf2d
@ -46,8 +46,8 @@ def _which(program):
|
||||
return os.path.isfile(fpath) and os.access(fpath, os.X_OK)
|
||||
|
||||
fpath, fname = os.path.split(program)
|
||||
if fpath and is_exe(program):
|
||||
return program
|
||||
if fpath and is_exe(os.path.abspath(program)):
|
||||
return os.path.abspath(program)
|
||||
else:
|
||||
for path in os.environ['PATH'].split(os.pathsep):
|
||||
path = path.strip('"')
|
||||
|
Loading…
Reference in New Issue
Block a user