Is there anyway I can list files by typing a command in the shell which lists all the file names, folder names and their permissions in CentOS?
Have a look at tree, you may have to install it first. Per default tree does not show permissions, to show permissions next to the filename run
which will recursively list all folders and directories within the current directory including permissions.
This output can be processed mechanically if there are no newlines in your file names. If you replace
The output can be processed mechanically (special characters are sorted); in particular, it can be fed to