0

I have two ruby on rails websites which are almost identical. One is a development version and the other one is in production. The only place where they differ is in uploaded data, but that is not in the repository.

I have always just worked on the dev, fixed stuff, then I just sync the app directory over, or some of the files that I change. This has worked ok, until now.

Now I have barely touched these sites for over a year, and I have done some changes on both sides. Yes I know, I worked on the prod when I should not have.

Now, my question is this. Can I, easily merge these two projects (specifically the app directory) and then perhaps in the future, can I then work on the development project and once I am done, just push the changes over ?

I know how I might do this with help of other version controls, but I would like to know if this is possible using just fossil.

Trausti Thor
  • 3,722
  • 31
  • 41

1 Answers1

1

I think your life will be much easier, going forward, if you bite the bullet and get your two versions into one repository.

Suggested procedure:

Select one of the repositories.

Open it.

Delete all the user files

Add all the user files from the other repository.

Check in, creating a new branch.

Merge the branches. You will have to decide which branch to merge into.

ravenspoint
  • 19,093
  • 6
  • 57
  • 103
  • I think you are right. Will see if someone has a solution on this – Trausti Thor Oct 15 '12 at 21:42
  • Um, I do not understand what solution you are still looking for. Is there a step in my suggested procedure you do not understand? – ravenspoint Oct 15 '12 at 22:02
  • I don't know, something like 'fossil merge -mainsite /develop/site1 -othersite /develop/site2 -output /develop/site3', that would have been nice. I did this the hard way with diffs, history a lot of copy paste – Trausti Thor Oct 19 '12 at 18:23
  • Did you try it the way I suggested? You don't really describe what you did, but it sounds way harder than it needed to be! – ravenspoint Oct 19 '12 at 18:36
  • I did it like you suggested, then went over it with a fine tooth comb. There were some files that didn't auto merge, etc. Teaches me never to skip a step, even if this is a private project – Trausti Thor Oct 19 '12 at 18:48
  • OK. Any merge of significantly different branches usually needs some manual effort. Its a bore, but usually very straightforward. – ravenspoint Oct 19 '12 at 18:50