As I am doing this, I am (often) leaving symlinks in the old location pointing to the new.
The problem with such symlinks is that the filesystem never gets clean. Not until you actually delete the symlinks. But then you may not be able to find old references.
Version control .... yeah, but who wants to go through VC logs.
IDEA: mark such "legacy symlinks". Hide them by default. When code tries to follow such a symlink, return an error - but a special error, that a suitable UI could provide meaningful info about.
Something like HTTP status codes
- 3xx Redirection
- 301 Moved Permanently
- 308 Permanent Redirect
But we can do better:
Instead of returning an error and expecting the user to understand, we might allow the user to set configuration options that
- ? automatically follow such redirects ?
- with a verbose warning
- only if valid as of time T
- only if not conflicting with current redefinitions of the name.
etc.
Essentially providing some sort of version control functionality.
And encouraging true cleanups, while still keeping the "find out where it went functionality".