`ghcup upgrade` fails with `.ghcup/bin/ghcup: openFd: does not exist`
- Downloaded
ghcup
(mac) from https://downloads.haskell.org/~ghcup/. - Placed it in
dir
. - Symbolically linked it from
my-bin-dir
which is in `PATH. - Tried to upgrade as prompted.
$ ghcup upgrade
[ Info ] Upgrading GHCup...
[ Info ] downloading: https://downloads.haskell.org/~ghcup/0.1.12/x86_64-apple-darwin-ghcup-0.1.12
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 8796k 100 8796k 0 0 228k 0 0:00:38 0:00:38 --:--:-- 231k
[ Info ] verifying digest of: ghcup
[ Error ] CopyError "/Users/abel/.ghcup/bin/ghcup: openFd: does not exist (No such file or directory)"
It seems to rely that .ghcup/bin
always exists, but did not care to created it.
After manually adding this subdirectory of .ghcup
, upgrade worked.
Proposed fix of upgrade procedure: Create bin
if it does not exist yet.