sts4 icon indicating copy to clipboard operation
sts4 copied to clipboard

application.yml / properties: mark occurrences of ${} property references

Open kdvolder opened this issue 5 years ago • 0 comments

This a follow up ticket to https://github.com/spring-projects/sts4/issues/427

More specifically point number 1 for this comment:

https://github.com/spring-projects/sts4/issues/427#issuecomment-625378951

I beleave what is being asked for is a behavior similar to how Java language server implements 'mark occurrences' functionality when you select a variable name in the code.

I.e as show in screenshot below:

mark-occurences

However in our case it would instead do something similar when a property reference inside of a '${...}' is selected.

Example:

spring:
  application:
    name: foo
other:
   property: ${spring.application.name}

We place cursor inside the ${...} and it should mark 'name' as a 'occurrence'.

Since Java language server already does this, I think it shouldn't be too hard for us to do the same using existing LSP support.

Similar functionality could also be implemented for 'application.properties' as well.

kdvolder avatar May 08 '20 16:05 kdvolder