VSCode debugging while maintaining workspace

Dear Community,
I recently switched from Juno to VSCode and I was wondering how I can use the debugging in Juno-like style so that when I run a file, the existing workspace is read.
Currently, when I run a configuration (not in Run in REPL), a new terminal is open, the code runs and then terminates, closing also the terminal.
How could I maintain each session so that I don’t have to run everything again?
Let’s say my problems is composed by three files to run in a row; I would like to run the first two ones and then debug only the third one multiple times without having to run both 1 and 2 each time.
How can I do that in VSCode?
Thank you