Re: can anybody explain the following to a git noob?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



It would be nice if instead of a transcript, you provided us with a script
that duplicated your problem instead of having everyone on the git-list play
20 questions.

In any case, I'm going to try and explain what's going on.

On 22/05/09 15:46 +1200, Tim Uckun wrote:
git mv vendor vendor_new
fatal: source directory is empty, source=vendor/plugins/acts_as_audited,
destination=vendor_new/plugins/acts_as_audited

Try reading `man git-mv`. "...it renames <source>, which must exist...".

ls vendor/plugins/acts_as_audited/
CHANGELOG  generators  init.rb  lib  LICENSE  Rakefile  README  spec  tasks
test.txt

What was this `ls` for? Also, next time try doing `ls -a` so people know
what hidden files exist.

ls test
fixtures  functional  integration  mocks  test_helper.rb  unit  watir

Again, `ls -a`.

git mv test test_new
git commit -m 'renamed the test directory'

Where is `git add .`?? Additionally, you must specific the `-a` flag on `git
commit` to apply the commit to files you removed.

********Checkout master. WTF?: Both the test and the test_new directories
exist. Why does the test_new exist in this branch?
git checkout master
ls
app  Capfile  config  db  doc  lib  MyProject.kpf  public  Rakefile  README
script  test  test_new  tmp  vendor

This is because you didn't commit the deletion of test. I can't speak to
anything else. It's like telling you to change your tires when the engine
has disintegrated.

Best,
Dan
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]