simplify path building slightly
update to work with version 3 or 2 (prioritizes 3 over 2)