What I do in the command line:
cat file1 file2 file3 > myfile
What I want to do with python:
import subprocess, shlex
my_cmd = 'cat file1 file2 file3 > myfile'
args = shlex.split(my_cmd)
subprocess.call(args) # spits the output in the window i call my python program
os.sendfile()
-based solution is possible, see Reproduce the unix cat command in python