Launch Console Applications in the background
-
I'm making an IRC Bot for statictics and I need to launch it into the background(like eggdrop). This bot runs in linux with mono(Free .NET Implantation). Does anybody has any clue about this? Trully, if there evil in this world,
It lies within the heard of mankind
Shock The Dark Mage shock@romhack.net Main Project: Aeru IRC - http://www.sf.net/projects/aeruirc
-
I'm making an IRC Bot for statictics and I need to launch it into the background(like eggdrop). This bot runs in linux with mono(Free .NET Implantation). Does anybody has any clue about this? Trully, if there evil in this world,
It lies within the heard of mankind
Shock The Dark Mage shock@romhack.net Main Project: Aeru IRC - http://www.sf.net/projects/aeruirc
If I remmeber correctly you add an ' &' to the command line in Linux, this will run the process in the background. Hope it works, let me know :) WebBoxes - Yet another collapsable control, but it relies on a "graphics server" for dynamic pretty rounded corners, cool arrows and unlimited font support.
-
If I remmeber correctly you add an ' &' to the command line in Linux, this will run the process in the background. Hope it works, let me know :) WebBoxes - Yet another collapsable control, but it relies on a "graphics server" for dynamic pretty rounded corners, cool arrows and unlimited font support.
Thanks again leppie, but if you know how to program it in the program rather than using the &, let me know. Trully, if there evil in this world,
It lies within the heard of mankind
Shock The Dark Mage shock@romhack.net Main Project: Aeru IRC - http://www.sf.net/projects/aeruirc
-
I'm making an IRC Bot for statictics and I need to launch it into the background(like eggdrop). This bot runs in linux with mono(Free .NET Implantation). Does anybody has any clue about this? Trully, if there evil in this world,
It lies within the heard of mankind
Shock The Dark Mage shock@romhack.net Main Project: Aeru IRC - http://www.sf.net/projects/aeruirc
In UNIX, in order to have the program put itself in the background, it needs to fork a child process. True system daemons are double-forked. The first fork puts the program in the background, the second fork isolates itself from the current process group (e.g., a user's session). However, Windows has never supported the concept of fork(), so it would be surprising to see it in .NET. It appears that Mono is closely following the .NET SDK to make sure that Mono (.NET) programs are cross-platform, but in case there is a concept of fork() within Mono, go with that. For a 100% pure .NET cross-platform program, I'd suggest you take a peek at System.Diagnostics.Process.