fleshed out perl script
updated mockup