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
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
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
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:
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:
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
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
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 -
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
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
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
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
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:
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
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
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
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,
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
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
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
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 ...
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
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
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
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
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
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
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
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
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!
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
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();
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;
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();
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,
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,
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.
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
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
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.
40 matches
Mail list logo