From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28326 invoked from network); 14 Oct 1998 17:38:19 -0000 Received: from math.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 14 Oct 1998 17:38:19 -0000 Received: (from list@localhost) by math.gatech.edu (8.9.1/8.9.1) id NAA03941; Wed, 14 Oct 1998 13:31:21 -0400 (EDT) Resent-Date: Wed, 14 Oct 1998 13:31:21 -0400 (EDT) From: Phil Pennock Message-Id: <199810141738.SAA02973@athenaeum.demon.co.uk> Subject: Re: v3.1.4 Files/mv bug In-Reply-To: <199810140948.KAA20183@diamond.tao.co.uk> from Zefram at "Oct 14, 98 10:48:00 am" To: zefram@tao.co.uk (Zefram) Date: Wed, 14 Oct 1998 18:38:23 +0100 (BST) Cc: zsh-workers@math.gatech.edu X-Disclaimer-1: Any views expressed in this message, where not explicitly X-Disclaimer-2: attributed otherwise, are mine and mine alone. Such views X-Disclaimer-3: do not necessarily coincide with those of any organisation X-Disclaimer-4: or company with which I am or have been affiliated. X-Personality: INTJ X-Mailer: ELM [version 2.4ME+ PL37 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Resent-Message-ID: <"zo_LU.0.Wz.e_D9s"@math> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/4431 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu Typing away merrily, Zefram produced the immortal words: > This is a deliberate feature. The logic is that you can't actually move > files across devices, and the purpose of mv is to move files, so mv can't > move files across devices. The historical versions that do a copy and > remove are actually providing behaviour radically different from what > mv is intended for. If you want a copy and remove, rather than a move, > you can use cp and rm yourself. So, just how POSIX-compliant is zsh aiming to be? What does POSIX actually require, anyway? I can see that the extra logic in a shell is not as ... pleasant ... as just a couple of system calls. But, either the shell could do it correctly or if the link(2) fails with EXDEV then automatically use the one in the PATH. This is a nice compromise, IMNSHO, since it allows efficiency in many cases whilst still providing 'expected' (if not actually required?) behaviour. Alternatively, since they're both GPL'ed, just rip the code from the FSF's GNU shell-utils or wherever mv(1) normally lives ... Surely mv is /intended/ to be used as history mandates. Hey, otherwise, why not redefine O_RDONLY & O_WRONLY to be toggle-bits with O_RDWR=(O_RDONLY|_WRONLY) on a new POSIX system. It's correct. Just brain-dead and stupid. Similarly for fudging mv. Perplexed (and opinionated), -- --> Phil Pennock ; GAT d- s+:+ a22 C++(++++) UL++++/I+++/S+++/H+ P++@ L+++ E-@ W(+) N>++ o !K w--- O>+ M V !PS PE Y+ PGP+ t-- 5++ X+ R !tv b++>+++ DI+ D+ G+ e+ h* !r y?