Doesn't tar do exactly this? -- Emile van Sebille emile at fenx.com --------- "Thomas Duterme" <thomas at madeforchina.com> wrote in message news:mailman.987235759.19334.python-list at python.org... > Hi everyone, > > So I need to build a very large file. Essentially, I need > to go through a directory and recursively append the > contents of each file from that directory to a file. > > Here's what I'm doing right now: > > for x in os.listdir('.'): > os.system('cat '+x+' >> mylargefile) > > Is there any smarter way to do this in python? > > Thanks, > Thomas >
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4