Cannot resolve dirty folder (Win7) [message #837369] |
Thu, 05 April 2012 15:35 |
Steve Goodrich Messages: 13 Registered: February 2010 Location: Colorado |
Junior Member |
|
|
Eclipse 3.7.1
CDT 8.0.1
EGit 1.3.0.201202151440-r
I have a CDT-based environment and we use git for our repositories. We've built EGit into the product, so now we have some wonderful "git" manipulation within the IDE.
On Linux this works wonderfully. After installation, the projects in the workspace get loaded when we first launch Eclipse and they show no dirty/staged/etc. decorations.
Not so much on Windows 7, though. Some of the files get installed with the wrong permissions (e.g. chmod values of 644 instead of 755 - discovered using "git diff" from the command line) and thus get marked "dirty" ('>' flag). OK, so that's an installer issue. No problem; we'll address that.
However, I cannot (or do not understand how to) clear the dirty flag. Within Eclipse I have tried reset (Soft, Mixed, and Hard) on the project and the dirty flag does not get cleared ("git diff" still shows permission differences).
Running "git reset --hard" from the command line does clean up the attributes (no more permission/file differences when running "git diff"), but the dirty flag is still set in the Project Explorer.
So... two questions:
1) How do I get Team > Reset > Hard to do the same in the IDE as "git reset --hard" does from the command line?
2) How do I get EGit to recognize that the workspace no longer has problems (and thus have it clear the dirty flag)?
I've only been using git for a month or two, so I'm relatively new to it. EGit I've only been using for a few weeks, so I'm less familiar with that side of things. Hence, don't be afraid to ask "noob" questions. It may be something quite simply that I've simply overlooked.
Thanks!
-- Steve G.
|
|
|
|
Re: Cannot resolve dirty folder (Win7) [message #844738 is a reply to message #837369] |
Sat, 14 April 2012 09:36 |
Robin Rosenberg Messages: 332 Registered: July 2009 |
Senior Member |
|
|
Steve Goodrich skrev 2012-04-05 17.35:
> Eclipse 3.7.1
> CDT 8.0.1
> EGit 1.3.0.201202151440-r
>
> I have a CDT-based environment and we use git for our repositories. We've built EGit into the product, so now we have some wonderful "git" manipulation within the IDE.
>
> On Linux this works wonderfully. After installation, the projects in the workspace get loaded when we first launch Eclipse and they show no dirty/staged/etc. decorations.
>
> Not so much on Windows 7, though. Some of the files get installed with the wrong permissions (e.g. chmod values of 644 instead of 755 - discovered using "git diff" from the
> command line) and thus get marked "dirty" ('>' flag). OK, so that's an installer issue. No problem; we'll address that.
>
> However, I cannot (or do not understand how to) clear the dirty flag. Within Eclipse I have tried reset (Soft, Mixed, and Hard) on the project and the dirty flag does not
> get cleared ("git diff" still shows permission differences).
>
> Running "git reset --hard" from the command line does clean up the attributes (no more permission/file differences when running "git diff"), but the dirty flag is still set
> in the Project Explorer.
>
> So... two questions:
> 1) How do I get Team > Reset > Hard to do the same in the IDE as "git reset --hard" does from the command line?
> 2) How do I get EGit to recognize that the workspace no longer has problems (and thus have it clear the dirty flag)?
If this is related to line-endings, things may appear better in the 2.0 snapshot. You can give it a try. Egit 1.3 doesn't
support autocrlf.
Another option is to make sure your workspace is using LF only and set core.autocrlf false. On Windows (Git for Windows)
core.autocrlf is true by default, which means checked out files end with CRLF even if checked-in with LF. After changing
the core.autocrlf value perform a git reset --hard.
-- robin
|
|
|
Powered by
FUDForum. Page generated in 0.03352 seconds