Play with the Cmd PATH

Reply

Join Date: Oct 2007
Posts: 1,951
Reputation: Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of 
Solved Threads: 214
Featured Poster
Duoas's Avatar
Duoas Duoas is offline Offline
Posting Virtuoso

Play with the Cmd PATH

 
0
  #1
Nov 19th, 2007
I'm always dinking with my PATH variable at the command prompt. But the supplied windows "path" command is (and has always been) pathetic.

Well, after my latest episode of typing "path" and getting 6!!! lines of clutter I had had enough. So I wrote this little utility that lets me do all the things I always want to do, and a few other things thrown in.

Get it here. (Download links are at the bottom of the page.) It should work on any 32-bit version of Windows.

Available as a binary or as full source code.

It works by temporarily injecting executable code in its parent's process (which should be cmd.exe), so if you are running an anti-virus it will complain at you the first time you run it. This is the only way to non-permanently modify environment variables in another process in Win32.

Enjoy!
Last edited by Duoas; Nov 19th, 2007 at 9:02 am.
Reply With Quote Quick reply to this message  
Join Date: Oct 2007
Posts: 1,951
Reputation: Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of Duoas has much to be proud of 
Solved Threads: 214
Featured Poster
Duoas's Avatar
Duoas Duoas is offline Offline
Posting Virtuoso

Re: Play with the Cmd PATH

 
0
  #2
Nov 26th, 2007
After writing it in C++, I realized that g++ produces fairly large executables... So I rewrote it in Pascal (compiles with Delphi and FPC, but I used Delphi because it produces the smallest exe).

I also found and fixed a couple of (small) errors along the way (nothing to worry about if you are using the earlier version).

Get the new exe and/or sources from the same link as above.

Enjoy!
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the IT Professionals' Lounge Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC