breuleux/earl-grey

REPL trims the first character of each line

Closed this issue · 1 comments

Hello,
I've install ear-grey via npm ("Earl Grey version zero"). Earl Grey REPL trims the first character of each line I write.

<> console.log{1}
E.syntax.undeclared: Undeclared variable: onsole

<interactive> 1:0-5
  1: onsole.log{1}

I think Earl Grey is a great project. I'm looking forward more documentation and examples.
Thank you for Earl Grey. Go on!

Yes, I think that is caused by a change in the repl module (I had the issue when I switched to iojs, though I had assumed it was just iojs -- apparently I was wrong). Basically, node's repl module wrapped every input in ()s, and I had to strip them out. Then they stopped doing that for some reason, so what's going on here is that the first character and the trailing newline are being stripped out.

I am closing because this is already fixed in master. I'll likely have a new release on npm in the coming week which adds generators, async/await, source maps and other niceties :)