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

Expand selection doesn't select the whole block + block declaration #1667

Open
1 task
shellwhale opened this issue Jan 12, 2024 · 2 comments
Open
1 task
Labels
enhancement New feature or request

Comments

@shellwhale
Copy link

Extension Version

v2.29.1

VS Code Version

Version: 1.85.1 (user setup)
Commit: Oee08dfOcf4527e40edc9aa28f4b5bd38bbff2b2
Date: (1 mo ago)
Electron: 25.9.7
ElectronBuildld: 25551756
Chromium: 114.0.5735.289
Node.js: 18.15.0
11.4.18329-electron.o
09 Windows_NT x6410M 9045

Operating System

Windows 10

Terraform Version

1.6.6

Steps to Reproduce

Go to a resource definition, example =


resource "aws_iam_policy" "custom_policy" { 
#^  Place your cursor at the beginning of the resource line

  count = 0
}

Use the >Expand Selection or the shortcut CTRL+SHIFT+RIGHT

Expected Behavior

image

Actual Behavior

image

Terraform Configuration

No response

Project Structure

No response

Gist

No response

Anything Else?

No response

Workarounds

No response

References

No response

Help Wanted

  • I'm interested in contributing a fix myself

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment
@shellwhale shellwhale added the bug Something isn't working label Jan 12, 2024
@jpogran
Copy link
Contributor

jpogran commented Jan 17, 2024

Hey @shellwhale, we don't currently advertise support of selection expansion in terraform-ls, so we don't currently provide this feature.

We can add this to the list of thing to support. Can you go into further detail about the use cases where expanding the selection will help? For example, in wanting to copy an entire block to past soemwhere else?

@jpogran jpogran added enhancement New feature or request and removed bug Something isn't working labels Jan 17, 2024
@shellwhale
Copy link
Author

shellwhale commented Jan 18, 2024

Hello @jpogran, yes, copying or moving a block is the main reason. But that's not all, it would be easier for code actions (ctrl+;), quick fixes, and the most recent modify using copilot.

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

2 participants