look at how npm handles this internally... its entirely possible we are redoing what npm has already done for us and we can simply reuse that logic.