Issue 1046 in tortoisegit: Cannot commit Add...ed and modified files at the same time.

34 views
Skip to first unread message

torto...@googlecode.com

unread,
Jan 18, 2012, 7:52:50 AM1/18/12
to tortois...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 1046 by juj...@gmail.com: Cannot commit Add...ed and modified
files at the same time.
http://code.google.com/p/tortoisegit/issues/detail?id=1046

What steps will reproduce the problem?
1. Have a file A committed in the repository.
2. Create a new folder B and a file C in that folder, and choose Add.. for
the folder B.
3. Make a modification to file A.
4. Choose Git Commit by right-clicking in the background of Windows
Explorer when in the root directory of the repository.

What is the expected output? What do you see instead?

TortoiseGit will list files added in the step #2 in the Commit dialog, to
be commited, but hides the modified file(s) in the step #1.

Instead, both files in #1 and #2 should be shown.

What version of the product are you using? On what operating system?
git version 1.7.7.1.msysgit.0
TortoiseGit version 1.7.5.0
Windows 7 64-bit

Please provide any additional information below.
See this screenshot
http://dl.dropbox.com/u/40949268/TortoiseGit/GitAddCommitBug.png

Step #1/#3: I have modified the file CMakeLists.txt
Step #2: I have added the folder src/tinyxml to the repository.
Step #4: I am trying to commit both the modified and the added files, but
TortoiseGit only shows the added files, and not the modified files. Note
that command line git status properly shows the set of files I have added
and modified.

torto...@googlecode.com

unread,
Jan 18, 2012, 7:56:53 AM1/18/12
to tortois...@googlegroups.com

Comment #1 on issue 1046 by juj...@gmail.com: Cannot commit Add...ed and

As a workaround, I currently first commit the added files, then commit the
modified files, amending the first commit.

torto...@googlecode.com

unread,
Jan 18, 2012, 8:00:58 AM1/18/12
to tortois...@googlegroups.com

Comment #2 on issue 1046 by juj...@gmail.com: Cannot commit Add...ed and

Actually, the workaround I just wrote is not working. When I check
the 'Amend Last Commit' checkbox to amend to the commit where I added the
files, the modified files disappear from the change list.

torto...@googlecode.com

unread,
Jan 18, 2012, 1:24:58 PM1/18/12
to tortois...@googlegroups.com

Comment #3 on issue 1046 by sstrickr...@gmail.com: Cannot commit Add...ed

Not reproducible here.

Tried upgrading TortoiseGit to 1.7.6, repository defect, ...?

For comment #2: This might depend on the state of the "Show difference to
last commit" checkbox.

torto...@googlecode.com

unread,
Jan 18, 2012, 6:58:10 PM1/18/12
to tortois...@googlegroups.com

Comment #4 on issue 1046 by juj...@gmail.com: Cannot commit Add...ed and

I tried the "Show difference to last commit" checkbox, which does show the
modified file, but I am still unable to choose both of them (modified, and
added files) to be committed in at the same time.

I will have to try to upgrade to 1.7.6.

The screenshot I produced was the second case when the issue occurred. The
first one was on a different repository (the first time I did not
understand there was a bug, and just blamed my poor memory thinking that I
had not made any changes, or perhaps I had already committed them.. but
later noticed the modifications popping up again)


torto...@googlecode.com

unread,
Feb 18, 2012, 1:00:30 AM2/18/12
to tortois...@googlegroups.com

Comment #5 on issue 1046 by pro-lo...@optusnet.com.au: Cannot commit
Add...ed and modified files at the same time.
http://code.google.com/p/tortoisegit/issues/detail?id=1046

I ran into something similar with 1.7.7 on a windows XP machine. Trying to
reproduced it now on my Win 7 machine and can't do it.

Will investigate more closely on the XP box when I get a chance.

torto...@googlecode.com

unread,
Jun 22, 2012, 7:03:18 PM6/22/12
to tortois...@googlegroups.com

Comment #6 on issue 1046 by sstrickr...@gmail.com: Cannot commit Add...ed
Can you help us debugging (or providing a repository)?

What TGit does is:
1. updating the index (i.e. git update-index; git update-index -q --refresh)
2. List files
- git diff-index --cached --raw HEAD --numstat -C -M (detect staged files)
- git diff-index --raw HEAD --numstat -C -M (detect changes)
- git ls-files -u -t (detecting deleted files)
- git ls-files -d (detect renames)

The results of step 2 are combined. What are the outputs of these commands?

torto...@googlecode.com

unread,
Aug 10, 2012, 9:53:51 AM8/10/12
to tortois...@googlegroups.com
Updates:
Status: Invalid

Comment #7 on issue 1046 by sstrickr...@gmail.com: Cannot commit Add...ed
No response for a long time. Please reopen and provide the requested
information if this issue is still valid for you.

Reply all
Reply to author
Forward
0 new messages