Sub rShellExecute (Command As String)
Dim Runner As String
Dim StdOut, StdErr As StringBuilder
StdOut.Initialize
StdErr.Initialize
Dim Result As Int
Dim Ph As Phone
Runner = File.Combine(File.DirInternalCache, "Runner")
Command = File.Combine(File.DirInternalCache, "command")
File.WriteString(File.DirInternalCache, "Runner", "su < " & Command)
File.WriteString(File.DirInternalCache, "command", "modprobe cifs" & CRLF & "modprobe aufs" & CRLF & "exit") 'Any commands via crlf, and exit at end
Result = Ph.Shell("sh", Array As String(Runner), StdOut, StdErr)
Log(Runner)
Log(StdOut.tostring)
Log(StdErr.tostring)