This makes it easy to take a buffer containing a path with relative references (i.e. .. or . path segments) and resolve all of those into a clean path. This can be applied to URLs as well as file paths which can be useful. As part of this, I made the drive-letter detection apply on all platforms, not just windows. If you give a path that looks like "c:/..." on any platform, it seems like we might as well detect that as a rooted path. I suppose if you create a directory named "x:" on another platform and want to use that as the beginning of a relative path under the root directory of your repo, this could cause a problem, but then it seems like you're asking for trouble.
Name |
Last commit
|
Last update |
---|---|---|
.. | ||
buffer.c | Loading commit data... | |
dirent.c | Loading commit data... | |
env.c | Loading commit data... | |
errors.c | Loading commit data... | |
filebuf.c | Loading commit data... | |
hex.c | Loading commit data... | |
oid.c | Loading commit data... | |
path.c | Loading commit data... | |
pool.c | Loading commit data... | |
rmdir.c | Loading commit data... | |
string.c | Loading commit data... | |
strmap.c | Loading commit data... | |
strtol.c | Loading commit data... | |
vector.c | Loading commit data... |