How to find the directory structure from the current node?
- From: StephaneLeFou <stephanelefou@xxxxxxxxx>
- Date: Sat, 12 Jul 2008 05:22:32 -0700 (PDT)
Hi,
I'm reformulating my question since it was missing a key element.
From a shell script, I'd like to put into a variable the lastdirectory node from the current node, using the "ls -R" command since
the script doesn't have a clue of the directory structure where it
resides.
As an example, suppose you have the following structure:
/disk1/apps/incoming/dir1/dir2/dir3/dir4
And the script is running from: /disk1/apps/incoming/
I'd like to put this into a variable:
"dir1/dir2/dir3/dir4"
using the "ls" command (or something else) piped in some way.
Thanks in advance for your tips.
.
- Follow-Ups:
- Re: How to find the directory structure from the current node?
- From: Chris F.A. Johnson
- Re: How to find the directory structure from the current node?
- From: Janis Papanagnou
- Re: How to find the directory structure from the current node?
- Prev by Date: Re: Google Groups searching is broken
- Next by Date: Re: How to find the directory structure from the current node?
- Previous by thread: How to find the last directory node from current node?
- Next by thread: Re: How to find the directory structure from the current node?
- Index(es):
Relevant Pages
|