Skip to content

Commit

Permalink
uninstall.sh: prevent deleting none related homebrew folder
Browse files Browse the repository at this point in the history
I uninstalled homebrew because of an problem.
Uninstaller prompted my to delete: /usr/local/MacGPG2/ which isn't a Homebrew related file so skip it to be shown on none deleted dirs and files by the script.
  • Loading branch information
pheiduck committed Dec 29, 2024
1 parent d86c784 commit aca485a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions uninstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -462,6 +462,8 @@ fi
dir_children "${HOMEBREW_REPOSITORY}" "${HOMEBREW_PREFIX}" |
sort -u >"${tmpdir}/residual_files"

grep -v "MacGPG2" "${tmpdir}/residual_files" >"${tmpdir}/filtered_residual_files"

if [[ -s "${tmpdir}/residual_files" && -z "${opt_quiet}" ]]
then
echo "The following possible Homebrew files were not deleted:"
Expand Down

0 comments on commit aca485a

Please sign in to comment.