From: padiolea@irisa.fr
To: "Sebastien Ferre" <sbf@aber.ac.uk>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] file copy
Date: Wed, 23 Jun 2004 18:37:26 +0200 (CEST) [thread overview]
Message-ID: <1069.81.249.221.239.1088008646.squirrel@mail.irisa.fr> (raw)
In-Reply-To: <40D9A7E7.2060703@aber.ac.uk>
> Hi,
>
> is there any function in OCaml for copying a file
> like with the Unix command 'cp' ? I wish to avoid
> using the function Sys.command to keep platform
> independency.
In fact there is no copy operation in a filesystem
(observe the output of the command 'strace cp /tmp/titi /tmp/titi').
You can emulate the copy by combining reading and writing,
as the cp do,
so in ocaml combining functions input and ouput.
> I could not find any neither in the standard library,
> nor in the Unix library.
>
> Cheers,
> Sébastien
>
> -------------------
> 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
>
-------------------
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:[~2004-06-23 16:37 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-06-23 15:55 Sebastien Ferre
2004-06-23 15:06 ` Maxence Guesdon
2004-06-23 15:20 ` skaller
2004-06-23 16:37 ` padiolea [this message]
2004-06-23 19:21 ` sylvain.le-gall
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=1069.81.249.221.239.1088008646.squirrel@mail.irisa.fr \
--to=padiolea@irisa.fr \
--cc=caml-list@inria.fr \
--cc=sbf@aber.ac.uk \
/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