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

Autocomplete on the retainOnDelete resource option #102

Merged
merged 1 commit into from
Sep 17, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions sdk/yaml/completion.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,9 @@ func (s *server) completeReference(c lsp.Client, doc *document, ref *Reference)
// all results to prevent the filter from being eaten by the host.
//
// For example:
// typePropertyCompletion(type({foo: string, bar: int}), "someType.") would
// complete to ["someType.foo", "someType.bar"].
//
// typePropertyCompletion(type({foo: string, bar: int}), "someType.") would
// complete to ["someType.foo", "someType.bar"].
func (s *server) typePropertyCompletion(t schema.Type, filterPrefix string) (*protocol.CompletionList, error) {
var props []*schema.Property
switch t := codegen.UnwrapType(t).(type) {
Expand Down Expand Up @@ -850,6 +851,8 @@ func completeResourceOptionsKeys(doc *document, keyPos protocol.Position, post p
"Map of providers for a resource and its children.", post.intoObject},
{"version", "string",
"Version specifies a provider plugin version that should be used when operating on a resource", post.sameLine},
{"retainOnDelete", "boolean",
"Retain on delete leaks the resource on delete instead of removing it from the underlying cloud", post.sameLine},
})
}

Expand Down
Loading