My script is something like this:
#!/bin/bash sudo teamviewer --daemon enable teamviewer sudo teamviewer --daemon disable
It works fine on its own, and it requests my password with a terminal window. So, now I want to make a launcher for it. I have this in my
[Desktop Entry] Version=1.0 Encoding=UTF-8 Type=Application Categories=Network; Name=TeamViewer 12 Comment=Remote control and meeting solution. Exec=gksu /path/here/Start.sh Icon=teamviewer
That way it requests my password with a pop-up instead of a terminal window, but doing this runs the whole script with sudo, which is a problem, because TeamViewer refuses to start with sudo. How can I solve this?