From subprocess import Popen, PIPE
process = Popen(['/home/hadoop/BackupFolders/','tree','.','-d'], stdout=PIPE, stderr=PIPE)
stdout, stderr = process.communicate()
Hello, I am trying to run these lines of code, to show the directory tree structure like Linux/Unix
does. I've gotten the tree structure to show but only for the current working directory.
Every time I enter the path and run, it says access denied
. I set the shell to true and false but it didn't work.
I want to be able to show the current working directory but also give the option to specify other paths.