trim() always removes the line separator in the end of the String
Removed uneeded setting
Extracted OperatingSystemUtils.getLineSeparator() to a constant