Reimplement CGI and URI modules for loading speed

Simply requiring "cgi" takes ~4 ms, while "uri" can take ~18 ms on Ruby
2.0.0, because loading either module results in Ruby interpreter having
to parse a huge amount of code, most of which is not needed for our
purposes.

For instance, we only use `CGI.escape` and `CGI.unescape`, and this
change provides a small replacement module that loads fast.

This also provides a lightweight URI::HTTP replacement that's able to
parse simple URLs. For the purpose of representing URLs of git remote
and handling API communication, this should be enough.
Fix stubbing that CGI & URI modules are loaded in Ruby 2.0.0

Simply adding e.g. "uri.rb" to $LOADED_FEATURES ($") does the job in all
Rubies prior to 2.0.0. However, 2.0 will happily load "uri.rb" from
stdlib when a next `require "uri"` ocurrs, seemingly ignoring the state
of $".

I have NO IDEA how immediately trying to `require` works here, but it
does the job of preventing the actual load of "uri.rb" immediately and
in the future as well.
Speed up hub execution in cukes by skipping RubyGems
Speed up load time by avoiding loading YAML

Due to its sheer size, requiring YAML takes ~21 ms on Ruby 2.0.0. To
handle hub's very simple config format, we won't need most of YAML's
features, so we can afford to reimplement YAML just for the syntax we
need to support the existing config format.
Avoid loading FileUtils; reimplement `mkdir_p`

Loading FileUtils can take more than 10 ms on Ruby 2.0.0, making the
require extremely wasteful for the purpose of just using a single method.