Skip to content

feature: Set environment variables for DAP configuration #280

Open

Description

@bnwa

Did you check the docs?

  • I have read all the docs

Is your feature request related to a problem? Please describe.

vscode-java-debug accepts all the same parameters as vscode’s launch.json. I have an app that depends on environment variables being set properly to execute but it appears the only user configuration available in nvim-java are profiles that accept VM and program args.

Describe the solution you'd like

Either Profile UI should accept and write a map of environment variables to the DAP configuration for Java or nvim-java should be able to read from a .vscode/launch.json as explained in the nvim-dap help.

Describe alternatives you've considered

nvim-jdtls auto-generates a minimal .vscode/launch.json but its unclear in that project how to use it to override its automatic configuration.

Additional context

No response

Activity

  1. bnwa commented on Jul 27, 2024

    @bnwa
    Author

    I notice its possible to populate environment variables to an nvim-java DAP configuration but is commented out here:
    https://github.com/nvim-java/nvim-java-core/blob/5b03dca22fee76524a89e1c2dc1d73a9f0b1a3bb/lua/java-core/adapters/init.lua#L26

    If the work thus is to update the Profile setup UI to populate that uncommented field, do you accept PRs?

  2. s1n7ax commented on Jul 27, 2024

    @s1n7ax
    Member

    Yes. Always!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions