Re: [Mono-list] Command line debugging

2013-08-13 Thread Ian Norton
You can run a program that will listen for monodevelop on a TCP port before it enters it's main method. $ mono --debug --debugger-agent=transport=dt_socket,address=0.0.0.0:12345,server=y,suspend=y myprogram.exe That will sit listening on port 12345 for a debugger to attach. On another host you

[Mono-list] Command line debugging

2013-08-10 Thread Matt Calder
We run a mono-based service out of the cloud. The server machines are headless, without windowing libraries installed. Is there a good way to debug code running under mono from the command line? For the most part we rely on mirrored environments that do have Monodevelop capability, but that

[Mono-list] Command line parameters with spaces

2011-01-20 Thread karolo84
Dear list / forum, I have tried to figure out the following by myself but so far I wasn't lucky: I have a .NET program that takes a SQL query as command line argument. If I now run that program under Windows, I simply quote the string and everything is fine: app.exe SELECT foo FROM bar WHERE

Re: [Mono-list] Command line parameters with spaces

2011-01-20 Thread calahatras
Didn't know that. This is not a solution, but since you should still get all arguments passed to your main function, a workaround may be to use string.Join. string one = string.Join( , args) To get all your arguments as one string. Regards Patrick -- View this message in context:

Re: [Mono-list] Command line parameters with spaces

2011-01-20 Thread Jonathan Pryor
On Jan 20, 2011, at 3:42 PM, karolo84 wrote: I have tried to figure out the following by myself but so far I wasn't lucky: I have a .NET program that takes a SQL query as command line argument. If I now run that program under Windows, I simply quote the string and everything is fine:

Re: [Mono-list] Command line parameters with spaces

2011-01-20 Thread karolo84
Hi all, having found nothing on the web when searching for it made me fear it will either be trivial or very special. [user@cluster ~]$ /opt/novell/mono/bin/mono /home/user/bin/a.exe SELECT foo FROM bar WHERE time='20090212'; args[0]=SELECT args[1]=foo args[2]=FROM args[3]=bar args[4]=WHERE

Re: [Mono-list] Command line parameters with spaces

2011-01-20 Thread Robert Jordan
On 20.01.2011 23:58, karolo84 wrote: Hi all, having found nothing on the web when searching for it made me fear it will either be trivial or very special. [user@cluster ~]$ /opt/novell/mono/bin/mono /home/user/bin/a.exe SELECT Is /opt/novell/mono/bin/mono a shell script by chance? Robert

Re: [Mono-list] Command line parameters with spaces

2011-01-20 Thread karolo84
Indeed it is: cat /opt/novell/mono/bin/mono #!/bin/sh . /opt/novell/mono/bin/mono-addon-environment.sh exec /opt/novell/mono/bin/mono.bin $@ -- View this message in context: http://mono.1490590.n4.nabble.com/Command-line-parameters-with-spaces-tp3228447p3228739.html Sent from the Mono -

Re: [Mono-list] Command line parameters with spaces

2011-01-20 Thread Robert Jordan
On 21.01.2011 00:39, karolo84 wrote: Indeed it is: cat /opt/novell/mono/bin/mono #!/bin/sh . /opt/novell/mono/bin/mono-addon-environment.sh exec /opt/novell/mono/bin/mono.bin $@ You must double quote $@: exec /opt/novell/mono/bin/mono.bin $@ Robert

Re: [Mono-list] Command Line Options on Windows and Linux

2010-10-05 Thread Jonathan Pryor
On Mon, 2010-10-04 at 19:47 -0700, Charlie Poole wrote: I'm using Mono.Options for nunit-console 3.0 and I'm running into a bit of a conflict of philosophy about chars that start options. NUnit has historically NOT recognized args starting with '/' as options on Linux, although it does allow

[Mono-list] Command Line Options on Windows and Linux

2010-10-04 Thread Charlie Poole
Hi All, I'm using Mono.Options for nunit-console 3.0 and I'm running into a bit of a conflict of philosophy about chars that start options. NUnit has historically NOT recognized args starting with '/' as options on Linux, although it does allow them on Windows. Mono.Options recognizes '/' as

Re: [Mono-list] Command Line Options on Windows and Linux

2010-10-04 Thread Gonzalo Paniagua Javier
On Mon, 2010-10-04 at 19:47 -0700, Charlie Poole wrote: Hi All, I'm using Mono.Options for nunit-console 3.0 and I'm running into a bit of a conflict of philosophy about chars that start options. NUnit has historically NOT recognized args starting with '/' as options on Linux, although it

[Mono-list] Command line reference (invoking, switches, etc)

2008-12-24 Thread SebastianGarth
Hi, I just downloaded the Mono package but was unable to find any reference for invoking from the command line (I would rather not use an IDE). Is there a complete reference available somewhere? Cheers, - Sebastian -- View this message in context:

Re: [Mono-list] Command line reference (invoking, switches, etc)

2008-12-24 Thread Sandy Armstrong
On 12/20/2008 09:33 AM, SebastianGarth wrote: Hi, I just downloaded the Mono package but was unable to find any reference for invoking from the command line (I would rather not use an IDE). Is there a complete reference available somewhere? man mono man gmcs Sandy

[Mono-list] Command Line Applications

2008-10-23 Thread Luke Mitchell
Hi, I've been searching for a while now but I can't find out if it's possible to run a C# Console application from the linux shell, just as if it were a linux command line app.. Is this possible, or do you need to be running a version of linux which has a GUI? Thanks for reading, -Luke -- View

Re: [Mono-list] Command Line Applications

2008-10-23 Thread Jensen Somers
Luke Mitchell wrote: Hi, I've been searching for a while now but I can't find out if it's possible to run a C# Console application from the linux shell, just as if it were a linux command line app.. Is this possible, or do you need to be running a version of linux which has a GUI? Thanks

Re: [Mono-list] Command line parsing

2007-01-31 Thread Paolo Molaro
On 01/31/07 Chris Seaton wrote: I'm using svn Mono on OS X. I wrote a program that prints out each arg on a line. [...] $ mono test.exe a b c a b c That's wrong - I would expect. a b c It's the shell's job to parse the command line isn't it? I'm using bash, and other programs,

Re: [Mono-list] Command line parsing

2007-01-31 Thread Chris Seaton
Ah yeah, I found the problem. I'm using a wrapper shell script to run mono on my program. #!/bin/sh mono foo.exe $@ When I call the script with a b c $@ comes out as a b c Lots of people use these wrapper scripts, don't they? How should I be doing it? Thanks Chris Seaton On 31 Jan

Re: [Mono-list] Command line parsing

2007-01-31 Thread Etienne PIERRE
On Wednesday 31 January 2007, Chris Seaton wrote: Ah yeah, I found the problem. I'm using a wrapper shell script to run mono on my program. #!/bin/sh mono foo.exe $@ When I call the script with a b c $@ comes out as a b c Lots of people use these wrapper scripts, don't they? How

[Mono-list] Command line parsing

2007-01-30 Thread Chris Seaton
Hi, I think mono may have a problem with command line parsing. I'm using svn Mono on OS X. I wrote a program that prints out each arg on a line. $ mono test.exe: a b c a b c However, $ mono test.exe a b c a b c That's wrong - I would expect. a b c It's the shell's job to parse the

Re: [Mono-list] Command Line Parsing

2005-11-08 Thread matt raffel
take a look at to http://www.mindspring.com/~matt.raffel/code/NET/ There are 3 classes that might help you ApplicationCommandLine.cs CommandlineArgument.cs CommandlineException.cs To use them do something like this: First build an array of acceptable commandline arguements, such as ...

Re: [Mono-list] Command Line Parsing

2005-11-08 Thread Oleg Deribas
Abe Gillespie wrote: 1. Is there a utility class out there that helps parse command line arguments in a standard way? More or less: http://nini.sourceforge.net/ -- Oleg smime.p7s Description: S/MIME Cryptographic Signature ___ Mono-list maillist

Re: [Mono-list] Command Line Parsing

2005-11-08 Thread Francisco T. Martinez
Abe Gillespie wrote: 1. Is there a utility class out there that helps parse command line arguments in a standard way? 2. I think I ran into a bug playing around with the command line. When I send an asterisk * as one of the arguments I get some weird stuff. On Windows it seems to work ok. Try

Re: [Mono-list] Command Line Parsing

2005-11-08 Thread Abe Gillespie
Thanks for the help, this is great stuff! I'll probably go with the code option just to make portability a breeze. Any thoughts on the bug (maybe?) I encountered. I'll file it if someone confirms it. Thanks again! -Abe On 11/8/05, Francisco T. Martinez [EMAIL PROTECTED] wrote: Abe Gillespie

Re: [Mono-list] Command Line Parsing

2005-11-08 Thread Oleg Deribas
Abe Gillespie wrote: 2. I think I ran into a bug playing around with the command line. When I send an asterisk * as one of the arguments I get some weird stuff. Try to place asterisk in quotes like this: mono yourprogram.exe * -- Oleg smime.p7s Description: S/MIME Cryptographic

Re: [Mono-list] Command Line Parsing

2005-11-08 Thread Abe Gillespie
This works really well. I had to make one small change though to get it to work with my non-single-character arguments. ApplicationCommandLine.cs, Ln 142 - Change to: string argValue = args[count]; Thanks for the help! -Abe On 11/8/05, matt raffel [EMAIL PROTECTED] wrote: take a look at to

Re: [Mono-list] Command Line Parsing

2005-11-08 Thread matt raffel
oh.that is a good fix. :=) cool. Matt Abe Gillespie wrote: This works really well. I had to make one small change though to get it to work with my non-single-character arguments. ApplicationCommandLine.cs, Ln 142 - Change to: string argValue = args[count]; Thanks for the help! -Abe

[Mono-list] command line apps from ASP.NET

2005-07-22 Thread Chris Aitken
Hi All, I wrote the following: using System; using System.Diagnostics; public class GACReader { private static void Main() { System.Diagnostics.Process GACRead; GACRead = new System.Diagnostics.Process(); GACRead.StartInfo.FileName

Re: [Mono-list] command line apps from ASP.NET

2005-07-22 Thread Kornél Pál
But when: GACRead.StartInfo.Arguments = -l | grep Version=1; It returns nothing. Same result regardless of what is grep'd for. The | character is used to redirect the output of one command to another. It is not an argument for the executable it is interpreted by the shell. Also note that you

RE: [Mono-list] command line apps from ASP.NET

2005-07-22 Thread Chris Aitken
But when: GACRead.StartInfo.Arguments = -l | grep Version=1; It returns nothing. Same result regardless of what is grep'd for. The | character is used to redirect the output of one command to another. It is not an argument for the executable it is interpreted by the shell. Of course!

Re: [Mono-list] command line apps from ASP.NET

2005-07-22 Thread Kornél Pál
In the second (the C# source for an asp.net page), I am using GACRead.StartInfo.RedirectStandardOutput = true; To use this, UseShellExecute must be false, else the error: System.InvalidOperationException: UseShellExecute must be false when redirecting I/O. Then you have to specify the shell

[Mono-list] command

2004-08-09 Thread Fabian
Hi!. If i'm not wrong, if i want to execute a shell command like ls -lh I must paste the following code: System.Diagnostics.Process proc = new System.Diagnostics.Process(); proc.EnableRaisingEvents=false; proc.StartInfo.FileName= ls; proc.StartInfo.Arguments = -lh; proc.Start();

Re: [Mono-list] command

2004-08-09 Thread Jonathan Stowe
On Mon, 2004-08-09 at 14:15, Fabian wrote: Hi!. If i'm not wrong, if i want to execute a shell command like ls -lh I must paste the following code: System.Diagnostics.Process proc = new System.Diagnostics.Process(); proc.EnableRaisingEvents=false;

Re: [Mono-list] command

2004-08-09 Thread Fabian
El lun, 09-08-2004 a las 14:57, Jonathan Stowe escribi: On Mon, 2004-08-09 at 14:15, Fabian wrote: Hi!. If i'm not wrong, if i want to execute a shell command like ls -lh I must paste the following code: System.Diagnostics.Process proc = new System.Diagnostics.Process();

Re: [Mono-list] Command line processing tool in C#

2004-05-04 Thread A Rafael D Teixeira
Inline, Context of this thread: Now talking about Mono.GetOptions On Sun, 2004-05-02 at 14:27, Thomas R. Corbin wrote: On Thursday April 08, 2004 11:33 am, A Rafael D Teixeira wrote: Inline... This stuff is really excellent, and I am really enjoying using it. I'm wondering,

Re: [Mono-list] Command line processing tool in C#

2004-05-02 Thread Thomas R. Corbin
On Thursday April 08, 2004 11:33 am, A Rafael D Teixeira wrote: Inline... This stuff is really excellent, and I am really enjoying using it. I'm wondering, however, if there's a way to specify a default value for an option, for display in the --help output? On Wed,

Re: [Mono-list] Command line processing tool in C#

2004-04-08 Thread A Rafael D Teixeira
Inline... On Wed, 2004-04-07 at 21:59, Jonathan Pryor wrote: Below... On Wed, 2004-04-07 at 15:15, Thomas R. Corbin wrote: I've been using this tool in python: http://www.python.org/doc/2.3/lib/module-optparse.html And wondered if there was a similar tool in C# or for mono.

Re: [Mono-list] Command line processing tool in C#

2004-04-08 Thread Thomas R. Corbin
On Wednesday April 07, 2004 08:59 pm, Jonathan Pryor wrote: Below... On Wed, 2004-04-07 at 15:15, Thomas R. Corbin wrote: I've been using this tool in python: http://www.python.org/doc/2.3/lib/module-optparse.html And wondered if there was a similar tool in C# or for mono. There's a

[Mono-list] Command line processing tool in C#

2004-04-07 Thread Thomas R. Corbin
I've been using this tool in python: http://www.python.org/doc/2.3/lib/module-optparse.html And wondered if there was a similar tool in C# or for mono. If not, I was thinking about writing one for myself. BTW - is there something similar to Java's JMS for C#? One that's not tied to

Re: [Mono-list] Command line processing tool in C#

2004-04-07 Thread Jonathan Pryor
Below... On Wed, 2004-04-07 at 15:15, Thomas R. Corbin wrote: I've been using this tool in python: http://www.python.org/doc/2.3/lib/module-optparse.html And wondered if there was a similar tool in C# or for mono. There's a better one (in my obviously biased opinion): Mono.GetOptions.