Quantcast
Channel: How to get the PATH environment-variable separator in Python? - Stack Overflow
Browsing latest articles
Browse All 6 View Live

Answer by Shivam Bharadwaj for How to get the PATH environment-variable...

This is a sample path for your working directory/specific folder - import os my = os.path.sep+ "testImages" + os.path.sep + "imageHidden.png" print(my) Output for Linux-...

View Article



Answer by DVV for How to get the PATH environment-variable separator in Python?

OK, so there are: os.pathsep that is ';' and which is a separator in %PATH% environment variable; os.path.sep that is '/' in Unix/Linux and '\' in Windows, which is a separator between path components....

View Article

Answer by Nerrve for How to get the PATH environment-variable separator in...

Making it a little more explicit (For python newbies like me) import os print(os.pathsep)

View Article

Answer by Dave Costa for How to get the PATH environment-variable separator...

It is os.pathsep

View Article

Answer by SilentGhost for How to get the PATH environment-variable separator...

os.pathsep

View Article


How to get the PATH environment-variable separator in Python?

When multiple directories need to be concatenated, as in an executable search path, there is an os-dependent separator character. For Windows it's ';', for Linux it's ':'. Is there a way in Python to...

View Article
Browsing latest articles
Browse All 6 View Live




Latest Images