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

Suggest variable names as completion items #93

Closed
rcjsuen opened this issue Jul 20, 2017 · 1 comment
Closed

Suggest variable names as completion items #93

rcjsuen opened this issue Jul 20, 2017 · 1 comment
Assignees

Comments

@rcjsuen
Copy link
Owner

rcjsuen commented Jul 20, 2017

If the user types in a $ or invokes completion after a $, we should suggest a list of variables to the client. Since the brace syntax gets around whitespace issues, the brace syntax is what will be suggested. However, should a user start typing after the $ directly such as $v, then $var should be suggested even if ${var} was what was originally suggested.

By default, Docker includes the following variables that can be used without first declaring them in an ARG instruction:

  • HTTP_PROXY
  • http_proxy
  • HTTPS_PROXY
  • https_proxy
  • FTP_PROXY
  • ftp_proxy
  • NO_PROXY
  • no_proxy
@rcjsuen
Copy link
Owner Author

rcjsuen commented Jul 23, 2017

However, should a user start typing after the $ directly such as $v, then $var should be suggested even if ${var} was what was originally suggested.

Doesn't look like this is exactly possible. This is because clients may opt to filter the initial list after the user has started typing instead of going to the trouble of asking the server for items again. This seems fair from a performance perspective.

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

No branches or pull requests

1 participant