## Installation Add this line to your application's Gemfile: ```ruby gem 'UnitConverter' ``` And then execute: $ bundle install Or install it yourself as: $ gem install UnitConverter ## Usage UnitConverter serves a quite simple purpose: transferring units of volume and weight (e.g. in recipes) from the US system to metric and back. These functions of conversion are produced by two commands named massReplace(Imperial/Metric)Units, which are treating each instance of a unit separately according to conversion rules. ## Development After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment. To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org). ## License The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT). ## GEM UnitConverter serves a quite simple purpose: transferring units of volume and weight (e.g. in recipes) from the US system to metric and back. These functions of conversion are produced by two commands named find(Imperial/Metric)Units, which are treating each instance of a unit separately according to conversion rules. The supported units are: US: pound, ounce, pint, quart, gallon, inch Metric: liter, kilogram, gram, milligram, centimeter To convert, call UnitConverter.find(Imperial/Metric)Units("and input your text here") Dry fettuccine, 8 oz Olive oil, 2 tbsp Chopped bacon, 2 oz Minced garlic, 1 clove Lightly beaten eggs, 2 pcs Grated sharp white cheddar, 1/2 cup Salt and pepper, to taste Dry fettuccine, 240 gr Olive oil, 2 tbsp Chopped bacon, 60 g Minced garlic, 1 clove Lightly beaten eggs, 2 pcs Grated sharp white cheddar, 1/2 cup Salt and pepper, to taste