ruby: read stdout