From cb9f7476bea33a9864241243f1b4624622d7fb63 Mon Sep 17 00:00:00 2001 From: Kenny Ballou Date: Fri, 23 Mar 2018 16:53:16 -0600 Subject: use `fetch` or `pull --ff-only` over `git up` I now actually prefer just using fetch as it is more wildly available and easier to teach. --- src/code/5/9 | 4 ++-- src/git-in-reverse.tex | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/code/5/9 b/src/code/5/9 index ddc2875..a8f50e6 100644 --- a/src/code/5/9 +++ b/src/code/5/9 @@ -1,2 +1,2 @@ -[alias] - up = !git remote update -p +[pull] + ff = only diff --git a/src/git-in-reverse.tex b/src/git-in-reverse.tex index 14b7db4..37199a3 100644 --- a/src/git-in-reverse.tex +++ b/src/git-in-reverse.tex @@ -1110,7 +1110,8 @@ Signed-off-by: Junio C Hamano \item{Will force a merge, if drift between remote and local} \item{From the Git documentation~\cite{website:gitworkflows7}, ``Do not use \texttt{git pull} unless you actually want to merge the remote branch.''} -\item{I personally prefer creating an alias for \texttt{git-remote}} +\item{I personally prefer using \texttt{git-fetch} and \texttt{git-merge}} +\item{Another option: use \texttt{--ff-only} when pulling} \end{itemize} \lstinputlisting[title=\texttt{\~{}/.gitconfig}]{code/5/9} \end{frame} -- cgit v1.2.1