Server commander
#2
Yes, that should be very easy to create. Smile In fact, I just did it in under 5 minutes:


function Initialize(a_Plugin)
	a_Plugin:SetName("Shell Execute")
	a_Plugin:SetVersion(0)
	
	LOG("Shell Execute is initialized");
	
	cPluginManager:BindCommand("/shell", "shell.execute", HandleShellCommand, "Executes the given shell command")
	
	return true
end




function HandleShellCommand(a_Split, a_Player)
	local ShellCommand = table.concat(a_Split, " ", 2)
	local res = assert(io.popen(ShellCommand)):read("*all")
	
	a_Player:SendMessage(res)

	return true
end




Just pop that in "root/Plugins/ShellExecute/main.lua" or something and enable it Smile
I believe io.popen had some problems with Linux though.
Reply
Thanks given by:


Messages In This Thread
Server commander - by JuliB - 12-21-2015, 08:26 PM
RE: Server commander - by NiLSPACE - 12-21-2015, 08:39 PM
RE: Server commander - by JuliB - 12-21-2015, 08:50 PM
RE: Server commander - by NiLSPACE - 12-21-2015, 08:55 PM
RE: Server commander - by JuliB - 12-21-2015, 09:01 PM
RE: Server commander - by NiLSPACE - 12-21-2015, 09:11 PM
RE: Server commander - by JuliB - 12-21-2015, 09:17 PM
RE: Server commander - by NiLSPACE - 12-21-2015, 09:23 PM
RE: Server commander - by JuliB - 12-21-2015, 09:27 PM
RE: Server commander - by NiLSPACE - 12-21-2015, 09:49 PM
RE: Server commander - by jan64 - 12-21-2015, 10:50 PM
RE: Server commander - by xoft - 12-21-2015, 11:02 PM
RE: Server commander - by NiLSPACE - 12-21-2015, 11:03 PM
Alternate - by JuliB - 12-23-2015, 07:55 PM
RE: Server commander - by xoft - 12-23-2015, 08:25 PM
RE: Server commander - by JuliB - 12-23-2015, 09:43 PM



Users browsing this thread: 1 Guest(s)