Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Example of setting environment variables for codelldb#946

dpo started this conversation inGeneral
Discussion options

Hi,

I tried using the snippethttps://github.com/mfussenegger/nvim-dap/wiki/Debug-Adapter-installation#environment-variables for codelldb but I keep getting the a parse errorCould not parse launch configuration: invalid type: sequence, expected a map.

I also tried

env= {var1="value1",var2="value2",},

but that doesn't work either. I get the errorThe "program" attribute is required for launch. The program attribute is set correctly; it certainly works when I comment out theenv section.

Could you please give an example of how to set environment variables for the debug run?

Thanks!

You must be logged in to vote

Replies: 3 comments

Comment options

Are there some debug flags I can activate so I can see what is being passed to codelldb and, possibly, the json file that codelldb works with? Does my question pertain to this package or to codelldb itself? Thanks.

You must be logged in to vote
0 replies
Comment options

@dpo

I slightly modified the syntax to:

env=function()localvariables= {}fork,vinpairs(vim.fn.environ())dovariables[string.format("%s",k)]=string.format("%s",v)endreturnvariablesend,

and it worked for me.

You must be logged in to vote
0 replies
Comment options

Hi,

I tried using the snippethttps://github.com/mfussenegger/nvim-dap/wiki/Debug-Adapter-installation#environment-variables for codelldb but I keep getting the a parse errorCould not parse launch configuration: invalid type: sequence, expected a map.

I also tried

env= {var1="value1",var2="value2",},

but that doesn't work either. I get the errorThe "program" attribute is required for launch. The program attribute is set correctly; it certainly works when I comment out theenv section.

Could you please give an example of how to set environment variables for the debug run?

Thanks!

20250712_113730.jpg

2 years too late but is this what you were looking for?

You must be logged in to vote
0 replies
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Category
General
Labels
None yet
3 participants
@dpo@DrCheeseFace@croquemadame

[8]ページ先頭

©2009-2025 Movatter.jp