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

Document Go to Definition Functionality #35

Open
jpogran opened this issue May 26, 2020 · 0 comments
Open

Document Go to Definition Functionality #35

jpogran opened this issue May 26, 2020 · 0 comments
Assignees
Labels
documentation Improvements or additions to documentation
Milestone

Comments

@jpogran
Copy link
Contributor

jpogran commented May 26, 2020

We should document the Go to Definition functionality so that a user knows what is provided in which type of workspace. Some context to start with is below.

The extension should already detect if the folder opened is part of a control repository, so you shouldn't need to add

The rules to detect are:

  1. You must be opening a Folder (aka workspace) in VSCode, not a single file
  2. You must be opening a Folder either at the root of, or inside of, the control repo. Not outside of it.
  3. The control repo must contain an environment.conf
  4. The control repo must NOT contain a metadata,json file. If you have both, the extension will assume it's inside a module (not a control repo)

Now there are some cases where using that setting is needed. For example, I know that @genebean has a folder containing all of the download modules from Onceover, and he needs to add the Onceover path to get the intellisense.

Some code references:

https://github.com/puppetlabs/puppet-editor-services/blob/master/lib/puppet-languageserver/document_store.rb#L105-L132

https://github.com/puppetlabs/puppet-editor-services/blob/master/spec/languageserver-sidecar/integration/puppet-languageserver-sidecar/puppet-languageserver-sidecar_spec.rb#L226-L249

Originally posted by @glennsarti in puppetlabs/puppet-vscode#636 (comment)

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

No branches or pull requests

2 participants