maktaba#path#GetDirectory behavior needs more thought
Open
enhancement
- Dominant language
- Vim Script
- Stars
- 588
- Forks
- 41
- PR merge metrics
- No merged PRs in 30d
Description
`maktaba#path#GetDirectory` treats nonexistent paths as directories:
``` VimL
echo maktaba#path#GetDirectory('foo/bar/NONEXISTENT')
" --> foo/bar/NONEXISTENT/
```
Originally we had a variant that assumed files, not directories, but that was deleted. I would argue that assuming files in ambiguous cases is the more intuitive behavior, and we should detect trailing slashes so there's a mechanism to get the alternative behavior in cases where the caller already believes the nonexistent path should refer to a directory.
Contributor guide
Assessment
This issue has not been assessed yet.