Uninstalling all RubyGems

Standard

I was trying to clean up my Mac, this is when I wanted to uninstall all the Gems I installed on my system, removing them manually was a pain as some of them were dependencies and there were ways to many of them, so I discovered this way of removing all the RubyGems.

“`
for i in `gem list –no-versions`; do sudo gem uninstall -aIx $i; done
“`

Leave a comment below, if you have a better way to do this.

Composer on Mac

Standard

Composer is a dependency manager for PHP, that lets you manage dependencies by offering install/uninstall and options like creating projects.

It manages dependencies for you, big projects like Laravel framework and CMS like Grav use it to manage dependencies.

It’s easy to install it on Mac, all you have to do is run this curl command in your Terminal.

“`
curl -sS https://getcomposer.org/installer | php
“`

You will now have a `composer.phar`, which is executable.

You can move the file to the <code class="highlighter-rouge">/usr/loca/bin directory to make it accessible from anywhere.

```
sudo cp composer.phar /usr/local/bin/composer
```

Now when you run composer from your terminal you should get a greeting screen from Composer.