Page MenuHomePhabricator

Actually implement an `alias` field on Phurl URL's
Closed, ResolvedPublic

Description

The database column already exists, just need to expose it. Should be an optional field that auto-generates a value if no value is given.

per @epriestley:

The alias would be a unique alphanumeric string like "restart", which could not contain special characters. It also could not be purely numeric (for example, you can't give a link the alias 123, because then U123 and the aliased link would both have the URL /u/123.
If a link has an alias, both /u/2 and /u/restart would still work correctly (adding an alias doesn't break old links). The detail URL is still /U2, and the edit URL is still /phurl/edit/2/ or whatever.

Event Timeline

lpriestley claimed this task.
lpriestley raised the priority of this task from to Normal.
lpriestley updated the task description. (Show Details)
lpriestley added a project: Phurl.
lpriestley added a subscriber: lpriestley.

@epriestley I wrote in the original description (possibly after talking to you):

Should be an optional field that auto-generates a value if no value is given.

But isn't that what the ID already does? Is this still something you think we should do?

I don't think we need to auto-generate (and think it's slightly desirable not to -- I don't think we can do anything reasonable most of the time, and it will tend to make it harder to find a good alias when you actually want one if we do).

I think this is wrapped up. Any loose ends should be added as separate tasks.