How to make neko auto restart use script?

how to make neko auto reset use script?

       var p=	new Process("neko", [Sys.programPath(),"--reset", "true", "--from", "client", "--to", "reset"]);
	
	 
	   p.exitCode(true);//start another instance
		
	 
	   Sys.exit(0);//here is not excute.

There is no crossplatform way to truly restart a script,
one way is to use a wrapper executable that will restart your application if needed.

Your approach here should work, though you’d have two instances running, but that’s generally not an issue.