Reputation: 9085
I had this error when trying to commit.
dyld: Library not loaded: /usr/local/opt/icu4c/lib/libicui18n.67.dylib
Referenced from: /usr/local/bin/node
Reason: image not found
.husky/pre-commit: line 4: 20559 Abort trap: 6 yarn lint-staged
husky - pre-commit hook exited with code 134 (error)
It seems to be coming from node and its icu4c dependency
Upvotes: 27
Views: 30663
Reputation: 4320
I was having issues running coc.nvim
it seems some of the brew formulas were outdated and asking for an old version of icu4c.
In my case the outdated library was watchman so I ran
brew upgrade watchman
and that solved the issue, if you're not sure which library is outdated (you can see that just looking at the errors) you can just run brew upgrade
to update all formulas, of course, this could be risky so run with caution.
Upvotes: 0
Reputation: 31
In case there are others out there with the same sub issue:
If you need an outdated version of node (like node 14 now) brew won't let you install it, but you can use nvm
In that case you would do:
nvm uninstall node@14
nvm reinstall node@14
Upvotes: 1
Reputation: 317
Just try uninstalling node and icu4c e reinstalling (clean) again.
brew uninstall --ignore-dependencies node icu4c
brew install node
Upvotes: 4
Reputation: 9085
I just needed to do brew reinstall icu4c
, see https://gist.github.com/berkedel/d1fc6d13651c16002f64653096d1fded
Upvotes: 85