add ability to read from stdin