Working script for parsing local and remote files.