var sidebar_align = 'right';
var content_container_margin = parseInt('350px');
var sidebar_width = parseInt('330px');
Shell Script: Return Last Directory In A Path
I'm sure this is easy and has an obvious solution, I'm apparently being dense today and can't figure it out.
I have a list of paths, e.g.
What I'd like to do is just pull out and off that last directory, leaving behind
I think you'll want to use basename. Try typing:
Thanks Andrew, but I think basename gives me the opposite of what I'm hoping for, it just returns the last dir, I want everything *but* that last dir.
Oh, ok. Then you want dirname. That's the opposite of basename.
If the paths are stored in variables, try:
Last edited by hehachris; 01-07-2007 at
Rails in DA
- Ruby on Rails plugin for Directdmin |
- Tomcat Manager plugin for Directdmin
- PostgreSQL plugin for Directdmin |
IP Deny Manager
- IP Deny Manager plugin for Directdmin
- Manager your DirectAdmin server "deeper"
Order now at