be more idiomatic in passing filename
break up long line
break out csv write fn
fix thinko; merge csv fns back together; split up long line
move similar fns together
dedupe
break out org csv fn
merge functions back together