Given a CSV for input, this JS script will output a new CSV with additional columns containing the ISO 3166-1 alpha-3 country codes.
Requires npm, bower and grunt. To install the necessary packages and boot up an Express server:
npm install && bower install
grunt
Point the browser to http://localhost:9008/ to begin.