linuxify icon indicating copy to clipboard operation
linuxify copied to clipboard

linuxify uninstall fails because of python dependency

Open abulka opened this issue 5 years ago • 2 comments

Tried to uninstall and got this error:

$ ./linuxify uninstall
Error: Refusing to uninstall /usr/local/Cellar/[email protected]/3.9.1_6
because it is required by cairo, gdk-pixbuf, glances, glib, gobject-introspection, graphviz, gts, harfbuzz, imagemagick, libheif, liblqr, librsvg, pango, plantuml, shared-mime-info, sphinx-doc and termtosvg, which are currently installed.
You can override this and force removal with:
  brew uninstall --ignore-dependencies python

not sure whether to follow the advice of brew or do something else?

abulka avatar Jan 12 '21 01:01 abulka

Best is to keep these packages upon which others depend on, so as to not break anything.

Edit the linuxify script and replace line 142

brew uninstall -f $(echo "${linuxify_formulas[i]}" | cut -d ' ' -f1)

with

brew uninstall $(echo "${linuxify_formulas[i]}" | cut -d ' ' -f1) || true

and any errors there will be caught and ignored, effectively meaning any package that is depended upon will not be removed.

I'm rewriting the script so I'll take this in consideration. Thanks!

pkill37 avatar Jan 12 '21 18:01 pkill37

Hello! I faced the same issue. Do you think you could or should add a commit to add the || true part in uninstall? Thx :)

gerardbosch avatar Apr 03 '21 02:04 gerardbosch