Bug 581223 - Retain eclipse meta-data files when switching branches
Summary: Retain eclipse meta-data files when switching branches
Status: NEW
Alias: None
Product: EGit
Classification: Technology
Component: UI (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-12-14 07:32 EST by Christoph Laeubrich CLA
Modified: 2022-12-14 07:32 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christoph Laeubrich CLA 2022-12-14 07:32:56 EST
I noticed for some projects if they move things around, or unversion meta-data files I often get error messages when switching branches like this:

Problems occurred while refreshing local changes
Problems occurred while refreshing local changes
Errors occurred while refreshing resources with the local file system.
The project description file (.project) for 'org.eclipse.jdt.compiler.apt' is missing.  This file contains important information about the project.  The project will not function properly until this file is restored.
The project description file (.project) for 'org.eclipse.jdt.compiler.apt' is missing.  This file contains important information about the project.  The project will not function properly until this file is restored.

This can happen for example in the following case:

1) you have a branch where project files are checked in
2) you have a branch where files are not checked in

If you switch between those it happens that git removes the project file an afterwards one ends up with a broken workspace, need to remove the project manually and import the project again so eclipse creates the .project file again.

It would be good if egit could retain files required by eclipse of projects that are currently imported in the workspace (maybe mark them as "assume unchanged, keep them as unversioned, or whatever suffice), that should include

.project
.settings
.classpath