I'm using vs code for python development. I need to unclutter some std output of path whenever i run my python code.
Here below i run "Hello world" in a file any2.py - is there way to remove all that lengthy path before the actual output?
PS C:\Users\erjan\Desktop\kkkk> c:; cd 'c:\Users\erjan\Desktop\kkkk'; &
'C:\python38\python.exe' 'c:\Users\erjan\.vscode\extensions\ms-python.python-2022.12.1\pythonFiles\lib\python\debugpy\adapter/../..
\debugpy\launcher' '55841' '--' 'c:\Users\erjan\Desktop\kkkk\any2.py'
Hello world!
I dont know what this /debugpy/..adapter//launcher is all about, it is sometime tiring to read unrelated output
\debugpy\launcher'
You are using debug mode :
You can try Run Python File
, in front of command, only the path of Python interpreter will be displayed.
You can also try code-runner extension.
Then change the settings:
add the following code to this setting.json
:
"python": "python",
Here is the result in terminal:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.