I have a file path.. Is there any single command to see the file/directory permissions of all the intermediate directories in the path..?
|
Here are two oneliners. One
Output:
With just one call to
Output:
|
||||
|
|
||||
|
|
|
Linux comes with the
Otherwise, here's a way to iterate over the successive directories containing a given file (not the only one, as other answers on this page illustrate) and list their contents.
Note that this listing can be a little misleading in the presence of symbolic links. For example, if |
|||
|
|
|
I don't know of a short way to do so. For this task I use a shell script, you may find useful, too:
EDIT: Using an
|
|||||||||
|
|
Not so complicated, but this would help you I guess.
|
|||
|
|