Hmm... You got a fair point there. I thought about solving it with a File.join instead as that doesn't complain about the corner cases you mentioned. But then how to decompose the URL again on the berks (client) side? This would than again be impossible.

So thinking a little out of the box here, I thought about the fact that this peace of info/data doesn't have to be a valid URL. The point of this commit is to extend the passed info so it contains both the Github org+repo names and the web_endpoint value. But these are actually two separate values. So wouldn't a good/nice solution be to concatenate the two strings with a '@' in between them?

That way decomposing the string again is very easy, and the value itself still makes sense: location_path=web_endpoint@org/repo

Could this be an acceptable solution?