github issues: add TODOs, simplify logic, use doc/issues/ directory