Get Environment Variable using Python

os.getenv function

import os

envVar = os.getenv('PATH')

print(envVar)

Leave a Comment

Cancel reply

Your email address will not be published.