Page MenuHomePhabricator

Make repository URIs verbose by default
Open, LowestPublic

Description

Callsigns are now optional (T106130) but predictable and human-readable addresses still redirect to shorter ones with callsigns in them.
For example https://phabricator.wikimedia.org/diffusion/ESAL/ should redirect to https://phabricator.wikimedia.org/r/project/mediawiki/extensions/SandboxLink (currently it is the opposite).

Event Timeline

This is not a technical limitation anymore. Repositories can have a long (and meaningless) name which becomes part of their url.

I think there might be some disagreement about what constitutes a 'pretty' url. I think you are asking for verbose which is arguably better than the current URL scheme but not necessarily pretty.

We could see if upstream will allow us to create custom uri for the paths.

I think there might be some disagreement about what constitutes a 'pretty' url. I think you are asking for verbose which is arguably better than the current URL scheme but not necessarily pretty.

See, at https://secure.phabricator.com/T4245 they wrote "Make repository URIs slightly prettier"

Aklapper renamed this task from Make repository URIs pretty by default to Make repository URIs verbose by default.Jun 6 2016, 9:42 AM
Aklapper triaged this task as Lowest priority.

@Aklapper why do you think pretty URIs are verbose? By definition pretty means good, verbose means bad

"Pretty" means 1000 different things to 1000 different people. My pretty might not be your pretty.

Please feel free to link to those definitions you're quoting as "verbose means bad" is news to me. :)

I think upstream want to make uri's more pretty. See https://secure.phabricator.com/T4245 please.

I think upstream want to make uri's more pretty. See https://secure.phabricator.com/T4245 please.

That task is marked as resolved as of now and many repositorys alreadyu use the new URI scheme, e.x see https://phabricator.wikimedia.org/source/mediawiki. Note that this doesn't redirect.
However, from https://phabricator.wikimedia.org/source/mediawiki/manage/uris/ it seems that URIs for this new scheme need to be added manually, for example https://phabricator.wikimedia.org/source/extension-sandboxlink will give you a 404.

While the task descrption asks to redirect URIs to a verbose name, I don't know if there is a way to implement this at the moment (or if it is really necessary), but what can be achieved is a simple naming structure below /source which has verbose names, as far as I can tell it "just" needs somebody to add those URIs to the repository configuration. That's a lot of work if it needs to be done for each repository, I'm not sure if this can be done automatically. But before this can be started we should decide on a consistent naming system. I'd think it would be best to follow the naming we have in github, which is the very same as in gerrit except that it doesn't allow "subfolders". This means what is named /mediawiki/extensions/example in gerrit will be mediawiki-extensions-example in diffusion instead. I think that is a good scheme as human user can easily remember as they still can use the same names as in gerrit and just have to replace / by - . When it comes that we might redirect something to these repositorys one day it might also be easy to rewrite URIs accordingly.

So, am I right when thinking that what needs to be done to resolve this task is to add the /source/whatever URI to each repository? (At least as a first step, not thinking about redirects at the moment)