Start New Discussion within our Software Development Community

How can I start a launcher from python?
if I do: os.system("~/localhost") it just returns a number (probably a process id or something)

if this is not possible, how can I start from python a terminal window
and execute a code in that terminal?
(without closing the python script)

Thanks in advance =)

I found out the launcher is actually called: localhost.desktop
but if I do: os.system("~/localhost.desktop") it just starts my standard editor and shows the script...

I found out the launcher is actually called: localhost.desktop
but if I do: os.system("~/localhost.desktop") it just starts my standard editor and shows the script...

I don't know ubuntu very well, but if your launcher is related to a bash script, the script must be somewhere in the filesystem, so locate the script and call os.system(path_to_script) or subprocess.Popen(["bash", path_to_script]) .

This question has already been answered. Start a new discussion instead.