GithubHelp home page GithubHelp logo

ngopina / homebrew-rmtree Goto Github PK

View Code? Open in Web Editor NEW

This project forked from beeftornado/homebrew-rmtree

0.0 1.0 0.0 164 KB

Remove a formula and its unused dependencies

License: MIT License

Ruby 100.00%

homebrew-rmtree's Introduction

homebrew-rmtree

Remove a formula and its unused dependencies

What is it?

It's an external command for Homebrew that provides a new command, rmtree, that will uninstall that formula, examine its dependencies and uninstall them as well if there are no remaining formula that depend on them. The command will check all dependencies recursively starting at the one specified on the command line.

This is tricky business. The command as it stands right now is pretty straight-forward. So this command comes with a warning.

Warning

There are formulas that do not specify all of their dependencies. This means that it is possible that this command will remove something you still need. Until someone comes up with a clever way around this, you need to be careful what you uninstall.

Usage

Although the script's name is brew-rmtree.rb, Homebrew external commands work in such a way that you invoke it as brew rmtree. (It functions exactly like a sub-command built into Homebrew.)

$ brew rmtree libmpc08
Uninstalling /usr/local/Cellar/libmpc08/0.8.1...
Found lingering dependencies
mpfr2
Removing dependency mpfr2...
Uninstalling /usr/local/Cellar/mpfr2/2.4.2...
Found lingering dependencies
gmp4
Removing dependency gmp4...
Uninstalling /usr/local/Cellar/gmp4/4.3.2...

Installation

You can install brew rmtree in two ways.

  1. Tap this repository and install via brew itself.

    $ brew tap beeftornado/rmtree && brew install beeftornado/rmtree/brew-rmtree
    
  2. Install manually.

    $ git clone https://github.com/beeftornado/homebrew-rmtree.git && cd homebrew-rmtree
    $ mv brew-rmtree.rb /usr/local/bin/ && chmod 0755 /usr/local/bin/brew-rmtree.rb
    

Once you've installed via either method, you can use the command as described above.

homebrew-rmtree's People

Contributors

beeftornado avatar jawshooah avatar

Watchers

 avatar

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.