I have scripts that were written for XP that used c:\documents and settings, and c:\winnt

What is the best way to modify ten so that they take in concideration the fact that the to OS's use different paths?

0 Comments   [ - ] Hide Comments


Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
Answer this question or Comment on this question for clarity


It depends on the language your scripts are written in. Just use environment variables and you won't have to worry about it.
Answered 03/01/2010 by: airwolf
Tenth Degree Black Belt

Please log in to comment
use environment variables...which is what you ought to have done in the first place. Hard-coding paths, especially those which the OS resolves for you, is never a good idea.
Answered 03/02/2010 by: VBScab
Red Belt

Please log in to comment
understood but I am with a company now that has done just that and i am trying to clean up the mess.
Answered 03/02/2010 by: dwilson
Senior Yellow Belt

Please log in to comment
Check the OS version and condition your CA to execute accordingly
Answered 03/02/2010 by: mekaywe
Brown Belt

Please log in to comment