4 ms·
I actually spent time wrestling with exactly this earlier today, and I think I finally have a 2 line solution for it: https://pastebin.com/5WCXb2Gg https://pas
by not_skynet 5y ago
I actually spent time wrestling with exactly this earlier today, and I think I finally have a 2 line solution for it:
https://pastebin.com/5WCXb2Gg https://pastebin.com/5WCXb2Gg
Assuming `foo.bar` is a script inside the package `foo` that you want to both import and run directly (without `python -m ...`), this lets you do so without too much hassle.