Refactor

- use an helper
- use yum cookbook
- use URI to create url
- Fix problem with "name" resource != new_resource.name
- Add a default value for `type`

Based on #2
OK, perhaps then the right thing to do would be to remove `'default' => 'gem'` in `attributes/default.rb` above.