Skip to content

Commit

Permalink
cross platform aware path separator for PATHS collection
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-cherel committed Dec 17, 2014
1 parent fbfed1c commit 9b650b2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ld_lib_path.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import sublime, sublime_plugin
import platform
from os import environ
from os import environ, pathsep

# this script relies on the ld_lib_path_original and ld_lib_path_settings globals defined below

Expand All @@ -19,8 +19,8 @@ def ld_lib_path():
global ld_lib_path_original
global ld_lib_path_settings

# concatenations with ':' (colon) join, just like the PATH environment variable
environ[ld_path_env_name()] = ':'.join(ld_lib_path_settings.get("ld_library_path_items", []))
# concatenations with platform specific path separator (eg ':' colon on UNIX, ';' semicolon on windows)
environ[ld_path_env_name()] = pathsep.join(ld_lib_path_settings.get("ld_library_path_items", []))

def plugin_loaded():
global ld_lib_path_original
Expand Down

0 comments on commit 9b650b2

Please sign in to comment.