From: Sergey Vlasov <vsu@altlinux.ru>
To: Junio C Hamano <junkio@cox.net>
Cc: git@vger.kernel.org
Subject: [BUG] git-mv fails with "source directory is empty" when it should not
Date: Sun, 3 Dec 2006 16:57:25 +0300 [thread overview]
Message-ID: <20061203135725.GA7971@procyon.home> (raw)
[-- Attachment #1: Type: text/plain, Size: 922 bytes --]
Hello!
In some cases git-mv fails with "source directory is empty" when this
is definitely not the case.
Example (run in an empty directory):
$ git init-db
defaulting to local storage area
$ mkdir ab; touch ab.c; touch ab/d
$ git add .
$ git commit -m 'initial'
Committing initial tree f2dd231ec22a1d4376d4a6eadf49d87dd34ac2a0
$ git mv ab a
fatal: source directory is empty, source=ab, destination=a
However, at this point the source directory is definitely not empty:
$ git ls-tree -r HEAD
100644 blob e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 ab.c
100644 blob e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 ab/d
$ ls -ogR
.:
total 4
drwxr-xr-x 2 4096 Dec 3 16:47 ab
-rw-r--r-- 1 0 Dec 3 16:47 ab.c
./ab:
total 0
-rw-r--r-- 1 0 Dec 3 16:47 d
$ git status
nothing to commit
This happens both in v1.4.4.1 and in current 'master' (v1.4.4.1-g278fcd7).
--
Sergey Vlasov
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
next reply other threads:[~2006-12-03 13:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-03 13:57 Sergey Vlasov [this message]
2006-12-03 19:42 ` [PATCH] git-mv: search more precisely for source directory in index Johannes Schindelin
2006-12-03 20:04 ` Sergey Vlasov
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=20061203135725.GA7971@procyon.home \
--to=vsu@altlinux.ru \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
/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;
as well as URLs for NNTP newsgroup(s).