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

Parse heredoc syntax correctly when processing completion items #87

Closed
rcjsuen opened this issue Aug 8, 2021 · 0 comments
Closed

Parse heredoc syntax correctly when processing completion items #87

rcjsuen opened this issue Aug 8, 2021 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@rcjsuen
Copy link
Owner

rcjsuen commented Aug 8, 2021

const lib = require("dockerfile-language-service");
const service = lib.DockerfileLanguageServiceFactory.createLanguageService();
console.log(service.computeCompletionItems("RUN ", { line: 0, character: 4 }).length);
console.log(service.computeCompletionItems("RUN <<eot\n", { line: 1, character: 0 }).length);
0
19

We need to support the new heredoc syntax support added in moby/buildkit#2132. The second call is returning all the instructions as completion items when we're not actually on a new line.

@rcjsuen rcjsuen added the enhancement New feature or request label Aug 8, 2021
@rcjsuen rcjsuen self-assigned this Aug 8, 2021
@rcjsuen rcjsuen closed this as completed in 933cb10 Aug 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant