From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Nicolaescu Newsgroups: gmane.emacs.bugs Subject: bug#1408: 23.0.60; git/*vc-dir*: does not register a symbolic link which befor was a directory with one singel file Date: Sun, 28 Dec 2008 10:28:40 -0800 (PST) Message-ID: <200812281828.mBSISePg022740@mothra.ics.uci.edu> References: Reply-To: Dan Nicolaescu , 1408@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1230489828 16249 80.91.229.12 (28 Dec 2008 18:43:48 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 28 Dec 2008 18:43:48 +0000 (UTC) Cc: 1408@emacsbugs.donarmstrong.com, rfrancoise@debian.org To: Gregor Zattler Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Dec 28 19:44:54 2008 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LH0dB-0003ed-Dn for geb-bug-gnu-emacs@m.gmane.org; Sun, 28 Dec 2008 19:44:53 +0100 Original-Received: from localhost ([127.0.0.1]:45391 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LH0by-00032u-2y for geb-bug-gnu-emacs@m.gmane.org; Sun, 28 Dec 2008 13:43:38 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LH0bm-0002y6-BA for bug-gnu-emacs@gnu.org; Sun, 28 Dec 2008 13:43:26 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LH0bk-0002xC-FI for bug-gnu-emacs@gnu.org; Sun, 28 Dec 2008 13:43:25 -0500 Original-Received: from [199.232.76.173] (port=54559 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LH0bk-0002x6-52 for bug-gnu-emacs@gnu.org; Sun, 28 Dec 2008 13:43:24 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:51128) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1LH0bj-0007k9-KA for bug-gnu-emacs@gnu.org; Sun, 28 Dec 2008 13:43:23 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mBSIhLej007269; Sun, 28 Dec 2008 10:43:21 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id mBSIe4wO006179; Sun, 28 Dec 2008 10:40:04 -0800 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Dan Nicolaescu Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs , owner@emacsbugs.donarmstrong.com Resent-Date: Sun, 28 Dec 2008 18:40:04 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 1408 X-Emacs-PR-Package: emacs,vc-dir X-Emacs-PR-Keywords: Original-Received: via spool by 1408-submit@emacsbugs.donarmstrong.com id=B1408.12304891054736 (code B ref 1408); Sun, 28 Dec 2008 18:40:04 +0000 Original-Received: (at 1408) by emacsbugs.donarmstrong.com; 28 Dec 2008 18:31:45 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from sallyv2.ics.uci.edu (sallyv2.ics.uci.edu [128.195.1.120]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mBSIVbVo004730; Sun, 28 Dec 2008 10:31:38 -0800 Original-Received: from mothra.ics.uci.edu (mothra.ics.uci.edu [128.195.6.93]) by sallyv2.ics.uci.edu (8.13.7+Sun/8.13.7) with ESMTP id mBSITWfI015683; Sun, 28 Dec 2008 10:29:32 -0800 (PST) Original-Received: (from dann@localhost) by mothra.ics.uci.edu (8.13.8+Sun/8.13.6/Submit) id mBSISePg022740; Sun, 28 Dec 2008 10:28:40 -0800 (PST) In-Reply-To: (Gregor Zattler's message of "Fri, 21 Nov 2008 19:04:59 -0500") Original-Lines: 67 X-ICS-MailScanner-Information: Please contact the ISP for more information X-ICS-MailScanner-ID: mBSITWfI015683 X-ICS-MailScanner: Found to be clean X-ICS-MailScanner-SpamCheck: not spam, SpamAssassin (score=-1.44, required 5, autolearn=disabled, ALL_TRUSTED -1.44) X-ICS-MailScanner-From: dann@mothra.ics.uci.edu X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Resent-Date: Sun, 28 Dec 2008 13:43:25 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:23539 Archived-At: severity 1408 wishlist quit Gregor Zattler writes: > Disclaimer: I'm new to version control, perhaps I do not understand > the situation. These are the steps to reproduce the problem: > > $ mkdir vc-emacs-test > $ cd vc-emacs-test > $ git init > Initialized empty Git repository in /tmp/vc-emacs-test/.git/ > $ mkdir dir directory > $ echo test >dir/test > $ git add . > $ git commit -a -m "one" > Created initial commit cdd09ae: one > 1 files changed, 1 insertions(+), 0 deletions(-) > create mode 100644 dir/test > $ rm -rf dir > $ ln -s directory dir > $ emacs-snapshot -Q > > ^X v d > > now in buffer *vc-dir* looks like this: > > > VC backend : Git > Working dir: /tmp/vc-emacs-test/ > Branch : master > > ./ > unregistered dir > dir/ > removed dir/test > > > move cursor on this line type 'i' to register. Following error > messages are displayed: > > on the last line, copied from *Messages*: > vc-do-command: Running git update-index --add -- dir...FAILED (status 128) > > > In buffer *vc*: > > error: 'dir' appears as both a file and as a directory > error: dir: cannot add to the index - missing --add option? > fatal: Unable to process path dir > > > > > I think this is a bug because emacs should handle this case (at least > with a sensible message what to do). > > Actually this happend in a "real" scenario, I decided to reproduce a > minimalistic example. VC is not really prepared to deal with arbitrary commands on symlinks, so it's not surprising that this corner case fails. Changing a directory into a symlink between to VC operations is not something that happens very frequently...