From: Oliver Bandel <oliver@first.in-berlin.de>
To: Jens Olsson <jenso@operamail.com>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] Wildcard expansion/command line
Date: Tue, 14 May 2002 15:30:06 +0200 (MET DST) [thread overview]
Message-ID: <Pine.LNX.3.95.1020514152458.480A-100000@first.in-berlin.de> (raw)
In-Reply-To: <20020514075059.30862.qmail@operamail.com>
Hello,
On Tue, 14 May 2002, Jens Olsson wrote:
> Hello,
>
> This is my second time at the list. Feel good to be back :) Hope all of you are well!
>
> I have a question right away. It might not (probably not) be a Ocaml related question but I'll give it a shot!
>
> I write a program that is invoked from the command line. All well, but when I was starting to make my program deal with wildcards I realized that the ocaml program gets its command line arguments expanded (if wildcards are used). I have included an exam
ple at the bottom of my mail to clarify if it is unclear what I mean.
[...]
> Example call Command line arg within my program
> ./myprog m* -> Sys.argv.(1) = "m1.txt"
> ./myprog m?.txt -> Sys.argv.(1) = "m1.txt"
> ./myprog "m*" -> Sys.argv.(1) = "m*"
>
> ie, wildcards are expanded before given to my program.
This is typical bwehaviour of unix-shells, and that's what
they are good for. That's, why working with shells is so
easy. :)
If you don't want that behaviour, write your own shell, or
let your program explicitly read the arguments in.
Ciao,
Oliver
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
next prev parent reply other threads:[~2002-05-14 13:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-05-14 7:50 Jens Olsson
2002-05-14 8:24 ` Maxence Guesdon
2002-05-14 12:52 ` T. Kurt Bond
2002-05-14 13:11 ` Dave Mason
2002-05-14 13:30 ` Oliver Bandel [this message]
2002-05-14 15:52 ` John Max Skaller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.3.95.1020514152458.480A-100000@first.in-berlin.de \
--to=oliver@first.in-berlin.de \
--cc=caml-list@inria.fr \
--cc=jenso@operamail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox