Quantcast
Channel: Active questions tagged ubuntu - Stack Overflow
Viewing all articles
Browse latest Browse all 5956

Execute python script in console via bash script with double-click [duplicate]

$
0
0

I have a python script, that runs fine if i run in on the console with python3 script.py. For some reason, the script should be executed via a bash-script "start.sh". A MWE would be

#!/bin/bash python3 GUIpyPCS.py

When I run the script by double-clicking it, it doesent open a terminal window. Hence, the python script is executed invisibly in the background and not on a new console window.

How can I ensure, that the python script is executed on a console by double-clicking the bash-script? Is there something I can add to the bash script? I am currently testing on Kubuntu 20.04, but the solution should also applicable to other distributions/window managers.


Viewing all articles
Browse latest Browse all 5956

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>