[ale] SHELL: get file name

Zyman, Andy zymana at hra.nyc.gov
Tue Jul 2 12:54:11 EDT 2002


Hello,
Some time ago i had the question "how to get dirname". Now i decided to go
even further :) and get filename.
So here we go:
ABSFILE=/home/aaa/bbb/ddd/name.log

question:
how can i get "name.log"?
I need to be flexible on the location - cann't hardcoded location.
I want to achive this in one step.

Right now i'm doing :
dirn=`dirname $ABSFILE`
echo $ABSFILE | sed 's/\'$ABSFILE'//g' 

Thank You
 Andy

---
This message has been sent through the ALE general discussion list.
See http://www.ale.org/mailing-lists.shtml for more info. Problems should be 
sent to listmaster at ale dot org.






More information about the Ale mailing list