Skip to content
This repository has been archived by the owner on Jul 8, 2023. It is now read-only.

Home directory resolution system #33

Open
ezzatron opened this issue Nov 5, 2013 · 1 comment
Open

Home directory resolution system #33

ezzatron opened this issue Nov 5, 2013 · 1 comment

Comments

@ezzatron
Copy link
Contributor

ezzatron commented Nov 5, 2013

It's a common use case for paths to use ~ or ~user to indicate home directories. Pathogen should have a system for dealing with these cases.

Some things that probably need to happen:

  1. FileSystemPathFactoryInterface includes methods to get the current working directory, and system temporary directory. It probably needs to be expanded to have methods to get the current home directory, and the home directory of a specified user. They should always internally use the 'platform' path factory - this just ensures that they are Windows paths on Windows, and Unix-style on anything else.
  2. A new resolver at FileSystem\Resolver\HomeDirectoryResolver that implements the newly refactored PathResolverInterface and uses an instance of PlatformFileSystemPathFactory to produce home directory paths using the new methods created in 1. This resolver could probably cache home directory lookups, I assume they're unlikely to change at runtime.

This task could be tackled at the same time as #36.

@ezzatron
Copy link
Contributor Author

@darianbrown This task is pretty much ready to roll; I've finished my refactorings for now. Let me know if you're no longer interested though. Also, if you get on a roll, #36 is a pretty similar task!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant