Re: Problem with add folder to a subdirectory

Previous thread: [PATCHv6 4/6 RESEND] instaweb: add minification awareness by Mark Rada on Friday, April 2, 2010 - 5:40 pm. (1 message)

Next thread: Problem with git push on (somewhat) large binaries by Tobi Stadelmaier on Saturday, April 3, 2010 - 4:02 am. (1 message)
From: Aris Bezas
Date: Saturday, April 3, 2010 - 1:26 am

Hi,
I am new to git and i have a problem. I clone repo from a collaborator and i
want to add some folder to a subdirectory.
When i add a folder to the root dir ($ git add TestFolder) i have no problem
but when i try to put it in a different subdirectory like ($ git add
examples/TestFolder) then with the command ($ git status) i tsake no result
(nothing to commit (working directory clean)).

Thanks for your reply

Aris Bezas Sat, 03 April 2010, 11:26
-- 
View this message in context: http://old.nabble.com/Problem-with-add-folder-to-a-subdirectory-tp28125580p28125580.html
Sent from the git mailing list archive at Nabble.com.

--

From: Ramkumar Ramachandra
Date: Saturday, April 3, 2010 - 2:13 am

I suspect that you're trying to add an empty directory. Git tracks
content, not individual files and directories- so try adding some
content (read: a file), and then git-add'ing that.

-- Ram
--

From: Ramkumar Ramachandra
Date: Saturday, April 3, 2010 - 11:25 am

[Kindly do not cull the list from CC unless absolutely necessary]


Unless I've misunderstood something, I'm not able to replicate your
issue. Kindly go through some introductory material on Git.

$ git init
Initialized empty Git repository in /tmp/foo/.git/
$ mkdir -p 1/2
$ touch 1/2/test.txt
$ git add 1/2
$ git status
# On branch master
#
# Initial commit
#
# Changes to be committed:
#   (use "git rm --cached <file>..." to unstage)
#
#       new file:   1/2/test.txt
#

-- Ram
--

From: Bo Yang
Date: Saturday, April 3, 2010 - 8:26 pm

Hi Aris,

Are you sure in the root directory, you can add an empty directory to
the index? I don't think so. See:
https://git.wiki.kernel.org/index.php/GitFaq#Can_I_add_empty_directories.3F

Regards!
Bo
--

Previous thread: [PATCHv6 4/6 RESEND] instaweb: add minification awareness by Mark Rada on Friday, April 2, 2010 - 5:40 pm. (1 message)

Next thread: Problem with git push on (somewhat) large binaries by Tobi Stadelmaier on Saturday, April 3, 2010 - 4:02 am. (1 message)