From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lennart Borgman Newsgroups: gmane.emacs.devel Subject: Re: bug in copy-directory Date: Fri, 28 Jan 2011 17:51:00 +0100 Message-ID: References: <87ipxaidea.fsf@gmail.com> <87k4hp96g0.fsf@stupidchicken.com> <878vy59ejz.fsf@stupidchicken.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1296233500 27303 80.91.229.12 (28 Jan 2011 16:51:40 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 28 Jan 2011 16:51:40 +0000 (UTC) Cc: Thierry Volpiatto , Michael Albinus , Stefan Monnier , emacs-devel@gnu.org To: Chong Yidong Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jan 28 17:51:35 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PirXl-0001IN-Fb for ged-emacs-devel@m.gmane.org; Fri, 28 Jan 2011 17:51:29 +0100 Original-Received: from localhost ([127.0.0.1]:44327 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PirXk-00021g-RY for ged-emacs-devel@m.gmane.org; Fri, 28 Jan 2011 11:51:28 -0500 Original-Received: from [140.186.70.92] (port=48702 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PirXf-00021Z-TK for emacs-devel@gnu.org; Fri, 28 Jan 2011 11:51:24 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PirXe-00048A-Id for emacs-devel@gnu.org; Fri, 28 Jan 2011 11:51:23 -0500 Original-Received: from mail-ey0-f169.google.com ([209.85.215.169]:33989) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PirXe-000485-EE for emacs-devel@gnu.org; Fri, 28 Jan 2011 11:51:22 -0500 Original-Received: by eyh6 with SMTP id 6so1637909eyh.0 for ; Fri, 28 Jan 2011 08:51:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type:content-transfer-encoding; bh=PopCz/FQHQ1JDxOQrfON+FEzTDMfpurvYKlg5+O9TMk=; b=an+AJ6CfR9LHmfjs65FBujPEBVuy7Ku/8UBAp5B35bXxmKOhxd7qKQOKKWOyr7KkQa P1T08yeGnCR4s8geGAxntYrZy7DENrxAVmEoIdjCCvIWCA47QRdrU2N85vs+TsqMZ3qe XN+qwdc659aYSAlK5KJ/4gFM9JKIX938ejFsY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=Uqv7lwCi6JPnHEBnS4LcGgWuU3pyOe1yZyHekkxF2hhx2B2lUF6Cor2EUpuWg0sA4N 0MnuyokQkldf5D0IsRT0NH28KvRrg8QPPF7F+3YYBtzwmiGzd7QTe2wLuZl8/TlasGjj M5wdqyjuo6VmjnRwgc7uou8NCqpXZnlB589WU= Original-Received: by 10.213.3.3 with SMTP id 3mr4429734ebl.54.1296233480563; Fri, 28 Jan 2011 08:51:20 -0800 (PST) Original-Received: by 10.213.36.11 with HTTP; Fri, 28 Jan 2011 08:51:00 -0800 (PST) In-Reply-To: <878vy59ejz.fsf@stupidchicken.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.215.169 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:135156 Archived-At: On Fri, Jan 28, 2011 at 5:30 PM, Chong Yidong wrote= : > Stefan Monnier writes: > >>>> Actually on 23.2.92.1, copy-directory, called interactively or not cop= y >>>> the files of directory A to existing directory B instead of copying >>>> directory A inside directory B.(as a subdirectory of B). >> >>> Hmm, this is a bit problematic. >> [...] >>> The trouble is that Lisp callers might depend on the old behavior. >> >> Couldn't/shouldn't we distinguish between interactive and >> non-interactive calls, then? =C2=A0I.e. have the interactive spec turn t= he >> B into (expand-file-name (file-name-nondirectory A)) when B is an >> existing directory. > > Wouldn't that be confusing? =C2=A0"Copy directory A to directory B" reall= y > ought to mean the same as "cp -r a b". Isn't the semantics of "cp" broken + undescribed? I had a directory x1, but no x2. Doing cp -r x1 x2 works as I expect it to, i.e. x1 and x2 are identical. However after a second cp -r x1 x2 there is suddenly a directory x1 inside x2. I really dislike this kind of context specific semantics that is both unintuitive and undescribed.