Can you enable the setting in IntelliJ that adds a newline at the end of your files?