There is no limit, other than the size of your disk, and your file system limitations on a file.
For example, file size limits:
NTFS: 16 TiB - 64 KiB
Ext4: 16 TBs
FAT32: 4GB - 1
On disk, there is no difference between a text file and any other type of file. They all just store bytes of data.
The only conceptual difference when writing to a binary file and a text file is that when a write operation is performed on a text file, a \n character may be replaced with a \r\n character, or some other line ending character(s).
There is no limit, other than the size of your disk, and your file system limitations on a file.
For example, file size limits:
On disk, there is no difference between a text file and any other type of file. They all just store bytes of data.
The only conceptual difference when writing to a binary file and a text file is that when a write operation is performed on a text file, a \n character may be replaced with a \r\n character, or some other line ending character(s).