some quick cleanup
add options page and logic to respect options