Scriptify it.
Script handles errors and has usage.