SPECFEM / specfem3d

SPECFEM3D_Cartesian simulates acoustic (fluid), elastic (solid), coupled acoustic/elastic, poroelastic or seismic wave propagation in any type of conforming mesh of hexahedra (structured or not).
GNU General Public License v3.0
409 stars 227 forks source link

Branch and tag cleanup #4

Closed QuLogic closed 10 years ago

QuLogic commented 10 years ago

These branches appear unmerged, but should be merged or deleted:

These branches are merged and unnecessary:

There are lots of unnecessary tags:

komatits commented 10 years ago

Hi Elliott,

Yes, these branches can probably be removed. Regarding "coupling_vadim", please email Vadim Monteiller monteiller@geoazur.unice.fr to doublecheck.

Thanks, Dimitri.

On 11/12/2013 09:33 AM, Elliott Sales de Andrade wrote:

These branches appear unmerged, but should be merged or deleted:

  • coupling_vadim: From the description, this was merged into master, but not marked as such in SVN. See 21b7443 https://github.com/geodynamics/specfem3d/commit/21b74434 on master. *

    obsolete_old: This branch just contains renamed copies of basin_static and ORIGIN.

    *

    basin_static: The only standalone commit on this branch appears to be empty.

    *

    basin_static@16915: Continues as basin_static, so unnecessary.

    *

    sunflower: This is just a single commit, followed by the first SPECFEM3D_SUNFLOWER commit that is completely disjoint from master. They really should have been joined.

  • SPECFEM3D_SUNFLOWER: I believe this is merged in 43b1a09 https://github.com/geodynamics/specfem3d/commit/43b1a09c, but not correctly marked as a merge in SVN.
  • SPECFEM3D_SUNFLOWER.old: This is just one commit over SPECFEM3D_SUNFLOWER, with the commit renaming the branch. *

    obsolete_old_SPECFEM3D_SUNFLOWER.old: This is just one commit over SPECFEM3D_SUNFLOWER.old, with the commit renaming the branch.

    *

    update_temporary: The first commit on this branch claims it is "private", so not sure if it's been merged or not.

    *

    update_temporary@16915: Continues as update_temporary, so unnecessary.

    *

    ORIGIN: This is basically the first three commits from CVS, with some renames later on. I don't know why anyone bothered.

  • ORIGIN@16915: Continues as ORIGIN, so unnecessary.
  • ORIGIN@10678: Continues as ORIGIN, so unnecessary.

These branches are merged and unnecessary:

  • trunk@16915
  • trunk@10678
  • ORIGIN@9365

There are lots of unnecessary tags:

  • R_20021218@10678, R_20021218@9365, R_20021218@9368 R_20021218@16915 are all copies of R_20021218. However, this is really just a tag of the first commit from cvs2svn, so it's useless.
  • older_unidentified_obsolete_v1.4@14753, older_unidentified_obsolete_v1.4@14757, older_unidentified_obsolete_v1.4@16111, older_unidentified_obsolete_v1.4@16915 are older versions of older_unidentified_obsolete_v1.4. This is just a copy of v1.4 with some renames. I don't know why anyone bothered with it.
  • v1.4@10158, v1.4@10678 are older versions of v1.4
  • v1.4.1@10158, v1.4.1@10344, v1.4.1@10678, v1.4.1@16915 are older versions of v1.4.1
  • v1.4.3_BASIN@15626, v1.4.3_BASIN@16111, v1.4.3_BASIN@16915 are older versions of v1.4.3_BASIN
  • v1.4.4_last_BASIN, v1.4.4_last_BASIN@16915 are older versions of v1.4.4

— Reply to this email directly or view it on GitHub https://github.com/geodynamics/specfem3d/issues/4.

Dimitri Komatitsch CNRS Research Director (DR CNRS), Laboratory of Mechanics and Acoustics, UPR 7051, Marseille, France http://komatitsch.free.fr

QuLogic commented 10 years ago

According to the commit log for 21b7443, the merge of coupling_vadim was done by you, in fact.

komatits commented 10 years ago

Hi,

Yes, but please check with Vadim anyway to see if he is done with his project (I think so but I am not 100% sure).

Thanks, Dimitri.

On 11/12/2013 09:40 PM, Elliott Sales de Andrade wrote:

According to the commit log for 21b7443 https://github.com/geodynamics/specfem3d/commit/21b7443, the merge of coupling_vadim was done by you, in fact.

— Reply to this email directly or view it on GitHub https://github.com/geodynamics/specfem3d/issues/4#issuecomment-28331055.

Dimitri Komatitsch CNRS Research Director (DR CNRS), Laboratory of Mechanics and Acoustics, UPR 7051, Marseille, France http://komatitsch.free.fr

QuLogic commented 10 years ago

Copied from my email to cig-seismo. See https://github.com/QuLogic/specfem3d-clean. To be effective, one needs to replace this and all other clones, or you run the risk of introducing the previous commits.

QuLogic commented 10 years ago

Here is a short script to compare all branches and tags (just to verify that what I have locally is the same as what I uploaded and what you see):

for b in QA coupling_vadim devel master update_temporary \
 v1.4 v1.4.1 v1.4.3_BASIN v1.4.4 v1.4.4_last_BASIN v2.0.0 v2.0.1 v2.0.2; do
    (cd specfem3d; git checkout $b)
    (cd specfem3d-clean; git checkout $b)
    diff -qpNr --exclude .git specfem3d specfem3d-clean
done

Of course, this won't verify everything, but at least we won't re-start development with missing information.

QuLogic commented 10 years ago

Ack, sorry to be a bother, but I just noticed that the SPECFEM3D_SUNFLOWER branch had individual commits on it that are not in the cleaned repo. Because the first commit was disjoint and the last not merged, they got lost. To be clear, the code is still there, it's just that it appears as one large commit at the end of development, instead of several commits made over time.

@komatits: I just wanted to see if you're alright with it being one single commit at the end, or whether you want to restore the individual commits? If we do that and create proper merging, that would affect some of the downstream commits. From your first comment, it seems like you might be fine with it as it is now, but I just want to be sure.

komatits commented 10 years ago

That branch was really important thus let us make sure that we keep its entire history rather than a single commit at the end.

(if I remember correctly that branch replaced the trunk around the end of August, that's why you do not see any final merge; thus that is normal). What we did was to svn rename the trunk to something else, and then svn rename that branch to "trunk" for technical reasons that are a bit long to explain (basically that branch had drifted for a year and a half and had thus become some kind of second trunk, and the official trunk had become obsolete; unusual, but worked fine.

Thanks, Dimitri.

On 11/16/2013 09:11 AM, Elliott Sales de Andrade wrote:

Ack, sorry to be a bother, but I just noticed that the |SPECFEM3D_SUNFLOWER| branch had individual commits on it that are not in the cleaned repo. Because the first commit was disjoint and the last not merged, they got lost. To be clear, the /code/ is still there, it's just that it appears as one large commit at the end of development, instead of several commits made over time.

@komatits https://github.com/komatits: I just wanted to see if you're alright with it being one single commit at the end, or whether you want to restore the individual commits? If we do that /and/ create proper merging, that would affect some of the downstream commits. From your first comment, it seems like you might be fine with it as it is now, but I just want to be sure.

— Reply to this email directly or view it on GitHub https://github.com/geodynamics/specfem3d/issues/4#issuecomment-28622032.

Dimitri Komatitsch CNRS Research Director (DR CNRS), Laboratory of Mechanics and Acoustics, UPR 7051, Marseille, France http://komatitsch.free.fr

QuLogic commented 10 years ago

That branch was really important thus let us make sure that we keep its entire history rather than a single commit at the end.

OK, no problem, I already started working on this when I mentioned it on Friday. There was a bit of cleanup required because there were several object files, editor files, etc. that should never have been committed. An updated repo is here: https://github.com/QuLogic/specfem3d-clean

Not all of the repo is touched, only the part following the merge of the sunflower branch. That leaves (forced) updates to master, devel, QA, and coupling_vadim. I also renamed SPECFEM3D_SUNFLOWER to just sunflower, as the first part seemed redundant.

komatits commented 10 years ago

Great, thanks a lot! Sounds perfect.

(I'd just suggest keeping the name SPECFEM3D_SUNFLOWER instead of sunflower, otherwise most developers will wonder why)

thanks Dimitri

On 11/18/2013 11:02 PM, Elliott Sales de Andrade wrote:

That branch was really important thus let us make sure that we keep
its entire history rather than a single commit at the end.

OK, no problem, I already started working on this when I mentioned it on Friday. There was a bit of cleanup required because there were several object files, editor files, etc. that should never have been committed. An updated repo is here: https://github.com/QuLogic/specfem3d-clean

Not all of the repo is touched, only the part following the merge of the sunflower branch. That leaves (forced) updates to master, devel, QA, and coupling_vadim. I also renamed |SPECFEM3D_SUNFLOWER| to just |sunflower|, as the first part seemed redundant.

— Reply to this email directly or view it on GitHub https://github.com/geodynamics/specfem3d/issues/4#issuecomment-28742617.

Dimitri Komatitsch CNRS Research Director (DR CNRS), Laboratory of Mechanics and Acoustics, UPR 7051, Marseille, France http://komatitsch.free.fr

QuLogic commented 10 years ago

OK, we should have @eheien update the repo then, if everything seems good to you.

eheien commented 10 years ago

You mean overwrite https://github.com/geodynamics/specfem3d with https://github.com/QuLogic/specfem3d-clean? If so, let me know when I should go ahead. As much as possible, we should avoid making any more changes like this if anyone is actively developing SPECFEM3D.

QuLogic commented 10 years ago

Yes, unfortunately, that is what I mean. That one branch was completely disjoint and I forgot to merge it back in. Sorry about that.

If we're really adverse to changing history at this point, an alternative is to use git-replace. It's similar to the graft+rewrite we use right now, but without the rewrite and it can be shared. However, it does require git 1.6.5; I'm not sure what people might be using.

eheien commented 10 years ago

I'm fine with replacing the repository (please let me know whether to go ahead). We should just try to avoid doing this on a regular basis.

QuLogic commented 10 years ago

Is this going to be done soon, or should we look into using git replace instead?

eheien commented 10 years ago

I'm fine with doing it, I was just waiting for the go-ahead per my last message. Is it still OK to do, or will this replace other commits on the main repository?

QuLogic commented 10 years ago

Yes, it would replace commits on master, so the longer we wait, the worse it is. It may be too late already.

I can look into using git replace on the one merge commit that needs it.

eheien commented 10 years ago

OK, let me know if git replace will work. I'd rather not overwrite existing commits, but if we do we need to confirm with the authors so they can add them again.

QuLogic commented 10 years ago

OK, I tried it out with git replace. It's on https://github.com/QuLogic/specfem3d. I think at this time, you need to explicitly push or pull replacement objects:

git push origin 'refs/replace/*'
git fetch origin 'refs/replace/*:refs/replace/*'

It's not so bad if you don't pull the replacements, as you just see the sunflower branch as unmerged: screenshot from 2013-12-18 18 02 21

If you do pull the replacements, you would see this: screenshot from 2013-12-18 18 00 54

I'm not sure how well the GitHub interface copes, but I think the worst that can happen is it will appear "unmerged".

QuLogic commented 10 years ago

PS, as you can see, this replace repo retains the same hash for the master branch.

eheien commented 10 years ago

I'll replace the main repo with this one in a minute. Do we need to tell users to clone the repo again, or will this be compatible with current clones?

QuLogic commented 10 years ago

No, the only changes are the (new) sunflower branch and the replacement commits. They are free to pull the replacements, but it's not necessary.

You should be able to just do this:

git fetch QuLogic sunflower
git fetch QuLogic 'refs/replace/*:refs/replace/*'
git push origin sunflower
git push origin 'refs/replace/*'

assuming you have remotes named that way, but feel free to do a whole replacement, as I made sure to pull any new changes from here.

eheien commented 10 years ago

OK, I think I brought it over correctly. Can you take a look and let me know if you see any problems? Thanks for your help!

QuLogic commented 10 years ago

Looks good to me!