Linux – View all files in a website’s directory


Is it possible to list all files and directories in a given website directory from the Linux shell?

Something similar to:

ls -l some_directory

but instead of some_directory, it would be ls -l Obviously, the later will not work.

Best Answer

I was just wondering the same thing. The following is probably not the most efficient solution, but it seems to work. It recreates the directory structure of the webserver locally. (Found the first command via stackoverflow)

wget --spider -r --no-parent
ls -l