Assuming I have a .py script in ~/Scripts/script.py, how can I run it with the currently opened file in PyCharm 2020.3 Professional?
What I simply need is to bind a keyboard shortcut to a python ~/Scripts/script.py <current_file> command and see the output in console.
Edit: I guess I need a PyCharm equivalent of https://marketplace.visualstudio.com/items?itemName=formulahendry.code-runner
Simplest way would be to get AutoHotKey and use that, as it has a lot of functionality, and because I don't think you can set extra shortcuts in PyCharm, both versions. You could try this though in a separate file:
or if you need to give the second file as STDIN or input:
Warning though, the second will turn your otherfile.py into STDIN and therefore it will be readable line by line with
input()ExtraAHK Script for you: