I have two python files. One is memory file system and another is memory shell. I can access file system through python shell. However, there is another file, which is a dump file. I want to know how to read and display the contents of dump file in python by using cat and ls commands.
Asked
Active
Viewed 595 times
0
-
2Welcome to stack overflow! what do you mean by reading the file in python using cat and ls? those aren't python commands. Can you show us what you've tried and where you're stuck? See this guide on [how to ask a good question](https://stackoverflow.com/help/how-to-ask). – Michael Delgado Sep 14 '21 at 22:48
-
Yeah I know ls and cat, are not python commands, but we have a project where we read a dump file, which is a memory file system with directories, blocks, inodes, and content. Our goal is to define ls function and cat function in python, which emulates ls and cat commands of UNIX to list the directories of the dump file and it's contents. So, I need to know how to code ls and cat function in python, which replicates ls and cat of UNIX. – Tatakaye Sep 15 '21 at 23:22