<SCRIPT LANGUAGE="JavaScript"> </SCRIPT> <NOSCRIPT> </NOSCRIPT>
The solution I can think of is to recursively open the "." and ".."
directories, looking for the entries with the same inode and
building the path that way. But that seems to be what the Cwd
module does. And Cwd is a standard module, so you don't need to
install anything extra (if that's what you want to avoid) and you
don't have to reinvent the wheel. If you absolutely do not want to
use modules (even standard ones) for whatever reason, I would also
suggest what nardo said: look at Cwd.pm, extract the appropriate
functionality and put it in your code.

Thanks ZZamboni. That's sound advice. It is probably what i shall do, while at the same time, for anybody losing sleep over this (LOL) something came to my attention (that frayed, intermittently failing attention ...) about the context of my perceived need to find out about this: i probably won't have to do this after all.

The free Web serving at Tripod was the reason for this. I've wanted to take advantage of the 50 free MB i have there and i needed to make a script do some stuff .. kinda cool Perl stuff (when it works -- it already does elsewhere but not on Tripod, so it's not as bulletproof as I want it to be -- it will be posted for the Brothers to look over). Anyway, on Tripod, the user cgi server always sets the user cgi-bin dir as "root" and doesn't know of anything else in the Universe above that. That simplifies things meaning I know what `/'points to, now.

Anyway, good advice as I said, and i'll take a look at Cwd.pm when i decide its time to tackle this.


In reply to RE: Re: Out of a hole? by Intrepid
in thread Out of a hole? by Intrepid

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.