I am writing a program on a win32 system to navigate a Byzantine subdirectory
structure.
I am including features so you can search by text or
regular expressions. Then it would either jump to the directory if it’s your
only match or give you a list to select from.
I have everything working except I can’t change the
directory on exit of the program.
Here is what I have tried
chdir("c:\\"); #Doesn't Work
system("cd c:\\"); #Doesn't Work
system("start cmd -k c:\\"); #Works but opens a new command com up. Un
+wanted!
I have read that perl restores the path it was executed from on exit.
Is there any way to force it to not restore or restore the path I want??
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.