Usage To concatenate all your .txt files you need to drop this script to folder with .txt, and after you need to simply run it by this command: python script.py At the result you get new concatenated .txt file with naming all_COMPILETIME.txt