hoangKnLai / vscode-ipython

VSCode Extension integrating Editor with IPython console.
MIT License
18 stars 5 forks source link

Please consider add Windows Command Prompt default support in "terminal.integrated.defaultProfile.windows": "Command Prompt" #44

Closed psyrocloud closed 8 months ago

psyrocloud commented 9 months ago

Dear developer, this is a really nice vscode extension and I love it. However, there is a little flaw for the windows command prompt terminal. every time I press F5 and it can not open the ipython correctly.

(I have read your guidance and try to install another Git for Windows to enable the Git Bash, and it worked.) (And I think this will make a barrier for more windows users who don't use Git Bash often.)

I have a quick temporary solution that I made a bat file which name is i.bat to correct the string format in windows cmd.exe. Here is the quick i.bat file:


ipython --no-autoindent --InteractiveShellApp.exec_lines="%%load_ext autoreload" --InteractiveShellApp.exec_lines="%%autoreload 2"

With this solution, I just press another "i" and enter, the extension is working perfectly. the solution contains 2 key points: 1) Use " instead of ' in windows command prompt. 2) Use double % mark to output a correct % mark in the string that embraced by " ".

Please consider add this solution to your source file, thank you!

hoangKnLai commented 9 months ago

Thank you for the suggestion. I'll look into it 🙏

hoangKnLai commented 8 months ago

@psyrocloud, happy New Year!

Just publish an update that should resolve this issue. It should enable you to use PowerShell and/or CMD terminals. Let me know if this works for you. Thanks!

P.S. You should be able to use the extension naturally without having to use the additional .bat file.