Skip to content

Commit

Permalink
Improve instructions how to fix broken node & corepack homebrew insta…
Browse files Browse the repository at this point in the history
…llation
  • Loading branch information
lhotari committed Nov 22, 2024
1 parent 99907f3 commit 2e1ca48
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions contribute/document-preview.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ brew unlink node@20
brew install node@20
# recreate symlinks
brew link node@20
# delete broken symlinks in /opt/homebrew/bin
find /opt/homebrew/bin -type l ! -exec test -e {} \; -delete
# enable corepack, if the command fails, remove the conflicting files from `/opt/homebrew/bin` and try again
corepack enable
```
Expand Down
2 changes: 1 addition & 1 deletion preview.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ show_yarn_installation_help() {
echo "You will need to activate corepack by running:"
echo "corepack enable"
echo "Don't install yarn separately from a package manager. With Homebrew, uninstall any existing yarn installation with 'brew uninstall yarn'"
echo "You might have to run 'brew unlink node; brew link node; corepack enable' to fix the installation."
echo "You might have to run 'brew unlink node; brew link node; find /opt/homebrew/bin -type l ! -exec test -e {} \; -delete; corepack enable' to fix the installation."
echo "If 'corepack enable' fails due to file conflicts, remove the conflictings files manually from /opt/homebrew/bin and try again."
}

Expand Down

0 comments on commit 2e1ca48

Please sign in to comment.