Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Complete files from pwd #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

noctux
Copy link

@noctux noctux commented Aug 29, 2018

Often, it is useful to not only complete relative filepaths as relative
to the currently edited file, but also to complete files relative to
the current processes cwd (one example being scripts like sudoedit which copy the
script into a temporary file under /tmp by default and perform their
edits there but do not modify the cwd). This commit enables completion of files relative to the processes cwd.

This pull request currently is more a proposal, as it currently enables completion from pwd unconditionally.
However, this might not be desired in all cases. Yet, traditional approaches (such as matching on filetypes, having a bufferlocal enable/disable etc) all seem cumbersome to use for the end user. Furthermore, I personally do not see too much harm in enabling this completion variant globally (after all, the plugin runs async and the only visible result is a small number of additional completion candidates).

Often, it is useful to not only complete relative filepaths as relative
to the currently edited file, but also to complete files relative to
the current cwd (one example being scripts like sudoedit which copy the
script into a temporary file under /tmp by default and perform their
edits there).
@prabirshrestha
Copy link
Owner

Can you rebase with latest master.

Also would be good to have a flag for this which can be turned on or off.

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

Successfully merging this pull request may close these issues.

2 participants