How do you run an interactive process in Dart?
问题 The test below attempts to run the less pager command and return once the user quits. The problem is that it doesn't wait for user input, it just lists the entire file and exits. Platform: xubuntu 12.04, Dart Editor build: 13049. import 'dart:io'; void main() { shell('less', ['/etc/mime.types'], (exitCode) => exit(exitCode)); } void shell(String cmd, List<String> opts, void onExit(int exitCode)) { var p = Process.start(cmd, opts); p.stdout.pipe(stdout); // Process output to stdout. stdin.pipe