[cig-commits] r21984 - seismo/3D/SPECFEM3D/trunk/doc/Version_Control

lefebvre at geodynamics.org lefebvre at geodynamics.org
Mon May 6 09:27:34 PDT 2013


Author: lefebvre
Date: 2013-05-06 09:27:34 -0700 (Mon, 06 May 2013)
New Revision: 21984

Modified:
   seismo/3D/SPECFEM3D/trunk/doc/Version_Control/Git-SVN_Quick_Reference.tex
Log:
Additional directions for git-svn. How to merge in a clean way.
	modified:   Git-SVN_Quick_Reference.tex

Modified: seismo/3D/SPECFEM3D/trunk/doc/Version_Control/Git-SVN_Quick_Reference.tex
===================================================================
--- seismo/3D/SPECFEM3D/trunk/doc/Version_Control/Git-SVN_Quick_Reference.tex	2013-05-06 16:04:44 UTC (rev 21983)
+++ seismo/3D/SPECFEM3D/trunk/doc/Version_Control/Git-SVN_Quick_Reference.tex	2013-05-06 16:27:34 UTC (rev 21984)
@@ -50,6 +50,28 @@
   $ git checkout -b local/SPECFEM3D_GLOBE_ADIOS SPECFEM3D_GLOBE_ADIOS
 \end{verbatim}
 
+Merging a development branch into the trunk. The master branch should be merged
+beforehand into your development branch. This way the conflicts will only
+occure in the developement branch. This also helps to contribute with
+up-to-date modifications. Therefore, the following steps should be followed:
+\begin{enumerate}
+  \item \verb|git checkout master| -- Switch to the \texttt{master}.
+  \item \verb|git svn rebase| -- The \texttt{master} is now up-to-date with the repository.
+  \item \verb|git checkout mybranch| -- Switch to the branch you want to merge.
+  \item \verb|git merge master| -- Update \texttt{mybranch} with the
+\texttt{master}. When using git only \verb|--squash| is an option to bundle
+multiple modifications in a single one. When using git-svn, it is important to
+use the \verb|--no-ff| option, otherwise git will loose branch information.
+  \item \verb|git mergetool| -- If there is any conflict to solve.
+  \item \verb|git commit| -- Commit the merge.
+  \item \verb|git checkout master| -- Switch to the \texttt{master}.
+  \item \verb|git merge [--no-ff] branch| -- Update the \texttt{master} with \texttt{mybranch}.
+  \item \verb|git commit| -- Commit the merge.
+  \item \verb|git svn dcommit| -- Send the merge to the svn repository.
+\end{enumerate}
+
+
+
 \subsection*{Git -- Checking the status of the file}
 Before doing any modification it is mandatory to know which files are tracked, have been modified or deleted.
 



More information about the CIG-COMMITS mailing list