http://developer.mozilla.org/en/docs/Code_snippets:Running_applications
in windows I can put "c:\\windows\\cmd.exe" to run command prompt but what about linux ? what is the terminal path :) PS: did you see *new beta edition* of flashgot ? they only support wget & terminal in new beta edition (not publish yet !) On Jan 27, 2008 3:41 PM, Jesper Staun Hansen <[EMAIL PROTECTED]> wrote: > that was one tricky question. Used some time to find you an answer. This > will probably be my best guess: > http://developer.mozilla.org/en/docs/Code_snippets:Running_applications > > The way they run it is (look in components/flashgotService.js): > runNative: function(args, blocking, exeFile) { > try { > if (typeof(exeFile)=="object" > || (exeFile = this.exeFile).exists() > || this.createExecutable()) { > const > proc=CC['@mozilla.org/process/util;1'].createInstance(<http://mozilla.org/process/util;1%27%5D.createInstance%28> > CI.nsIProcess); > proc.init(exeFile); > this.log("Running " + exeFile.path + " " + args.join(" ") + " -- > " +(blocking ? "blocking" : "async") ); > proc.run(blocking,args,args.length,{}); > if (blocking && proc.exitValue != 0) { > this.log("Warning: native invocation of\n" > +exeFile.path > +"\nwith arguments <" > +args.join(" ") > +">\nreturned "+proc.exitValue); > } > return proc.exitValue; > } else { > this.log("Bad executable "+exeFile); > } > } catch(err) { > this.log("Error running native executable:\n" + exeFile.path + > " "+args.join(" ")+"\n"+err.message); > } > return 0xffffffff; > } > > > joe ertaba wrote: > > Hi, > > > > how can I access to *linux terminal* from "@mozilla.org/process/util;1 > > <http://mozilla.org/process/util;1>" > > > > I want to send some commands to terminal from my extension, some thing > > like run wget to get files ,... > > > > PS: recently Flashgot runs Wget in terminal window > > ------------------------------------------------------------------------ > > > > _______________________________________________ > > Project_owners mailing list > > [email protected] > > https://www.mozdev.org/mailman/listinfo/project_owners > > > > > _______________________________________________ > Project_owners mailing list > [email protected] > https://www.mozdev.org/mailman/listinfo/project_owners >
_______________________________________________ Project_owners mailing list [email protected] https://www.mozdev.org/mailman/listinfo/project_owners
