file selection and processing for Node.js