سؤال

I have local eclipse project which is significantly different (but related) to git/remote contents. I want to overwrite remote contents where ever conflicts exist (otherwise preserve remote files). I have to merge using egit, but not sure how to clone remote contents onto my local file system and then accept my local changes where ever the conflicts exist.

First problem I am having is this eclipse project I want to check in to git is not cloned from git repo. So how do I start the merge. I guess I have to clone first. If so, should I clone it to same local directory where my eclipse project (if so, is it guaranteed that cloning does not overwrite my local eclipse project, but merely merges).

I am using egit/eclipse.

UPDATE: As I learn more on egit, I am realizing working from command line is the usual practice. Anyway, I could resolve it as follows

1)copy .git folder from existing repo to local eclipse project (that I want to overwrite the repo with)

2)merge (from eclipse ->git view)

3)commit and push

هل كانت مفيدة؟

المحلول

Lesson learnt: While egit makes it natural for checkout and committ while working in eclipse, egit doesnt bring us all the features that git has to offer (a reason why most of the online documentation is command line arguments).

Downloaded git shell (windows) and that should put me on path to get more out of git on widows.

http://windows.github.com/

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top