regex - \r\n in scala parser for Windows/Unix -


this question has answer here:

i've got scala regex test parse string multiple lines. looks following:

val s = "this 1 line\r\n" +         "the second line\r\n" +         "third" 

scala test "\r\n" working windows, unix should keep "\n". common solution work on both systems?

you test \r?\n instead of \r\n. way carriage return optional.


Comments

Popular posts from this blog

javascript - three.js lot of meshes optimization -

smartface.io - Proper way to change color scheme for whole application -

Email notification in google apps script -