How to change path of log file when run with code-lens in vscode?

Hello everyone,
I don’t know how to change the path of the log file when I run the test case with the Run button. It’s just put all log, report, xml,… all files to the default working folder. It’s not good because I have a lot of files in my working directory. I want to put all logs in a specific folder to easily manage.
1

Thank you so much.

Hi Binh,

FYI Robot Framework doesn’t have a “Run button” or any other buttons, so I guess you are referring to a “Run button” in your Editor or IDE?

If you mention which IDE you are using hopefully someone else uses the same one can help (I can’t tell from the screen shot which one you are using)

Dave.

1 Like

Hi Dave
Thanks for your response.
I use VSCode with 2 plugins: Robocorp Code + Robot Framework Language Server.
VSCode has Run Button to run the specific test case, it’s very handy but it’s put all log files to my working directory (log, xml, report, and 100+ .png file :frowning: ), So I want to change path of log file for this feature.
Sorry, my English is not good.

Hi Binh,

Your english is great, no problems to understand :+1:t3: Unfortunately I never used VSCode, but others on this forum do hopefully someone can help :crossed_fingers:t2:

I did have a quick search for ‘Robocorp Code’ and browsed around a little and found this Robot YAML configuration format, maybe that’s where you can add command line options that get used when you click play, so maybe that’ll help.

Dave.

1 Like

@binhlt what you want is explained in robotframework-lsp/faq.md at master · robocorp/robotframework-lsp · GitHub

(i.e.: create a launch configuration named “Robot Framework: Launch Template” and customize it as needed – that link has more information on how to do that).