I\'m having a bit trouble of splitting a large text file into multiple smaller ones. Syntax of my text file is the following:
Try this bash script also
#!/bin/bash i=1 fileName="OutputFile_$i" while read line ; do if [ "$line" == "" ] ; then ((++i)) fileName="OutputFile_$i" else echo $line >> "$fileName" fi done < InputFile.txt