Added hackish support for reading input from STDIN