square/kochiku — pull request #75 by robolson (2014-05-19 16:56:39+00:00)
Title: Add concept of an alias for servers

I've added a server alias attribute to better handle the internal cname Square has for its Git server. So far we've tried to hack around it by having two separate entries in our config/application.yml but the kochiku script which calls BuildsController#create is still broken.

As you can see by the various commits, I went down the rabbit hole with this branch. I decided that it would be cleanest to implement the aliases if a Repository was represented by a host, a namespace, and a name rather than by a URL. As we've seen before with the addition of [canonical urls](https://github.com/square/kochiku/pull/54), the url format changes from one remote to another, whether you are fetching are pushing, and multiple formats are often supported. By representing a Repository by its three defining attributes (host, namespace, name), the right url can be constructed based on the situation and lookups of the Repository is simplified.

One change worth pointing out is the move of RemoteServer classes to lib folder. Originally they were in models but I do not see how that fits.

@square/kochiku-contributors