GithubHelp home page GithubHelp logo

Comments (13)

ggPeti avatar ggPeti commented on September 16, 2024 3

In the meantime I put together a quick hack to recursively remove dependencies. Check it out: https://github.com/ggPeti/homebrew-rmrec

from homebrew-rmtree.

beeftornado avatar beeftornado commented on September 16, 2024 2

Thanks for reporting this, and thanks for the detailed example. I'll look into this

from homebrew-rmtree.

jsfaint avatar jsfaint commented on September 16, 2024 1

Hi @Argon- My PR was already merged by @beeftornado
Thanks @beeftornado 😄

from homebrew-rmtree.

Argon- avatar Argon- commented on September 16, 2024

Unfortunately this repo seems to be dead/inactive. I guess it's best to settle for one of the forks to continue, e.g. https://github.com/jsfaint/homebrew-rmtree as it solves the (as of now probably most important) problem explained in #11

from homebrew-rmtree.

irundaia avatar irundaia commented on September 16, 2024

This issue is also a problem in the linked repo. I'd create an issue there as well, if the repo allowed the creation of issues

from homebrew-rmtree.

ilovezfs avatar ilovezfs commented on September 16, 2024

If you export HOMEBREW_DEVELOPER=1 the errors will be warnings so it at least won't go 💥

from homebrew-rmtree.

metakirby5 avatar metakirby5 commented on September 16, 2024

I got around this by adding the --ignore-dependencies flag to this line. I'm not sure if this is a "clean" solution, but it seems to have worked for me.

from homebrew-rmtree.

irundaia avatar irundaia commented on September 16, 2024

@metakirby5 Doesn't this mean that the dependencies aren't removed?

from homebrew-rmtree.

ilovezfs avatar ilovezfs commented on September 16, 2024

No.

If HOMEBREW_DEVELOPER is not set, and there are reverse dependencies using a formula, brew will error out if you try to remove that formula. --ignore-dependencies will suppress the error.

If HOMEBREW_DEVELOPER is set, and there are reverse dependencies using a formula, brew will issue a warning if you try to remove that formula. --ignore-dependencies will suppress the warning.

The fact that rmtree needs to use --ignore-dependencies means that it is in fact removing things that have reverse dependencies.

from homebrew-rmtree.

irundaia avatar irundaia commented on September 16, 2024

I'm not sure if this will be the behaviour I'm looking for though, as this might uninstall packages that might be needed for other packages.

from homebrew-rmtree.

ilovezfs avatar ilovezfs commented on September 16, 2024

@irundaia theoretically it should be fine because the cause is that the packages are being removed in the "wrong" order instead of all at once or in the "right" order. The "correct" fix here is to remove them in a single call to brew uninstall, "brew uninstall A B C D" or to do the uninstalls in an order that always removes a reverse dependency before its dependencies.

from homebrew-rmtree.

irundaia avatar irundaia commented on September 16, 2024

@ggPeti, I've tested your work, it seems to work fine :) It does seem to be a tad slow tbh. But I can deal with that. :)

from homebrew-rmtree.

beeftornado avatar beeftornado commented on September 16, 2024

Related to #21 #24

from homebrew-rmtree.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.