Skip to content

Document Go to Definition Functionality #35

@jpogran

Description

@jpogran

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)

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions