I'm having another go at path dependencies, and am trying to figure out how best to feed the local package versions into pubgrub. We have to do this so we don't end up with version miss-matches if a hex dependency also depends on a path dependency. We could either:
-
Change the package fetcher (bottom of
cli/dependencies.rs) to generate "fake" hex packages from the local dependency config. This would be a simple hack and would not require changing hexpm, but there some stuff in thehexpm::Releasetype (eg.outer_checksum) which I don't know how to generate. -
Change the
hexpmAPI so that thePackagetype is an enum supporting either hex packages or "pinned" local packages with a single release and no checksum. This would mean the code for local dependencies would be split across two projects, but it seems like maybe the right way to do it.
Any input on which of these seems like the right way to go?