Helper for R shell terminal multiple line editing