$ stack install ghcid-0.6.1
Run from outside a project, using implicit global project config
Using resolver: lts-5.10 from implicit global project's config file: /home/callen/.stack/global-project/stack.yaml
Populated index cache.
Error parsing targets: Specified target version 0.6.1 for package ghcid does not match snapshot version 0.5.1
Would be nice if this worked without my editing ~/.stack/global-project/stack.yaml. Any alternatives?
What do you expect to be able to do? You could edit your stack.yaml to point at some path where that version is available, and install it that way. Are you asking for a feature to specify that information - package location - on the command line? If so, I don't believe that's an option.
Here to me a straightforward solution would be to just clone the repo at that version and install it directly.
Looking to avoid having to edit any files, create any directories. Just want to install something and get the binary in my path.
I did end up adding it to my global stack yaml, but I don't think what I'm describing here is an unreasonable user request. It was something people could do with cabal-install.
I think this is a sensible idea, it's like temporarily changing the extra-deps list. Package identifiers temporarily add extra-deps. It may not be very useful for libraries, but it is indeed useful for executables. If it's a dependency of your package, then it will just get unregistered the next time you build.
Since it's easy, I've implemented it!
@mgsloan wow, thank you!
@mgsloan nice!
Also, this was a dupe of #1261 and should be closed as well :)
Most helpful comment
I think this is a sensible idea, it's like temporarily changing the extra-deps list. Package identifiers temporarily add extra-deps. It may not be very useful for libraries, but it is indeed useful for executables. If it's a dependency of your package, then it will just get unregistered the next time you build.
Since it's easy, I've implemented it!