« MBS Xojo plug-ins in … | Home | MBS Xojo / Real Studi… »

Sudo on Linux

We got a new LinuxSuMBS class for Linux to run commands as root if needed:

dim s as new LinuxSuMBS s.Command = "/usr/bin/whoami" s.User = "root" s.Alert = "Please Root?" s.Message "Can I install something for you?" if s.ExecuteSudo then MsgBox "OK" else MsgBox s.LastErrorMessage end if

Our example writes a little shell script and runs it as root. Could be useful to write an installer which updates a web app (As example). Of course this is for GUI apps and requires user to enter a root password. The biggest plugin in space...
02 02 16 - 16:43