Please support multiple installed versions of cabal
I would like to do both ghcup install-cabal <version1>
and ghcup install-cabal <version2>
and have the installed binaries not conflict with each other. Currently they both get installed as ~/.ghcup/bin/cabal
so the cabal from the command that was run most recently is the only one which will be installed. (Furthermore I would like that the binary installed by ghcup install-cabal <version>
is always the same for a fixed <version>
, though I believe this property holds already.)
This is important so that automated build and test systems, and locally-installed developer toolchains, can easily be set up to confirm that a codebase works under multiple cabal versions. When I filed an equivalent issue on the shell-script ghcup I was told that the reason it would not be addressed is that cabal versions are backwards compatible. However, this is not the case. The next version of cabal will be released with a breaking change (albeit small) and, more to the point, ghcup cannot guarantee that cabal versions will always be backwards compatible; indeed there may simply be unintentional breakage in a later version.
Being able to incrementally upgrade one's automated build system by trying new versions of tools before removing the old versions is really, really, important. The backwards compatibility offered by cabal is impressive but even so it does not obviate the need to test on multiple versions.
Naturally I can simulate this behaviour by manually copying the installed cabal to cabal-<version>
but that obviates the need for ghcup at all. It seems that what I am asking for is simple, useful functionality that can easily be added to ghcup and would be a quality of life improvement for many industrial users.