Skip to content
Browse files

fix repl completion and navigation

The readline interface of node has changed in [aad12d0][] and because of
that the autocompletion and key movement didn't work anymore. This
commit fixes this by checking whether stdin is in raw mode (i.e. invoked
as a script) or not (as a repl).

[aad12d0]: nodejs/node-v0.x-archive@aad12d0
  • Loading branch information...
1 parent f938a21 commit 01d4e87f57e10274785bd508b928dc2d686356d7 @heyLu heyLu committed May 20, 2012
Showing with 2 additions and 2 deletions.
  1. +1 −1 lib/coffee-script/repl.js
  2. +1 −1 src/repl.coffee
View
2 lib/coffee-script/repl.js
@@ -156,7 +156,7 @@
return repl.prompt();
};
- if (stdin.readable) {
+ if (stdin.readable && stdin.isRaw) {
pipedInput = '';
repl = {
prompt: function() {
View
2 src/repl.coffee
@@ -115,7 +115,7 @@ run = (buffer) ->
error err
repl.prompt()
-if stdin.readable
+if stdin.readable and stdin.isRaw
# handle piped input
pipedInput = ''
repl =

0 comments on commit 01d4e87

Please sign in to comment.
Something went wrong with that request. Please try again.