Tuesday, May 7, 2024
6
rated 0 times [  6] [ 0]  / answers: 1 / hits: 6179  / 1 Year ago, tue, april 18, 2023, 12:46:20

I never understand what "export" does. For example, what's the difference between these two?




  1. PYTHONPATH=/home/myaccount/ & export PYTHONPATH and

  2. PYTHONPATH=/home/myaccount/



One with export and the other without.


More From » environment-variables

 Answers
6

If you don't export, then the environment variable will only be visible locally. Exporting makes them available to other programs and shells you might launch (from that shell).


[#36719] Tuesday, April 18, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
ditery

Total Points: 9
Total Questions: 116
Total Answers: 119

Location: Grenada
Member since Sun, Dec 20, 2020
3 Years ago
;