diff --git a/docs/git/index.rst b/docs/git/index.rst index 9eac0f5..8663572 100644 --- a/docs/git/index.rst +++ b/docs/git/index.rst @@ -1,6 +1,38 @@ Git === +Configuration +------------- + +We recommend using: + +.. code-block:: bash + + git config --global init.defaultBranch main + git config --global push.autoSetupRemote true + git config --global merge.conflictstyle zdiff3 + git config --global diff.algorithm histogram + git config --global diff.colorMoved default + git config --global diff.colorMovedWS allow-indentation-change + +You might also like (requires installing `difftastic `__): + +.. code-block:: bash + + git config --global diff.tool difftastic + +If you sign commits, `tell Git about your signing key `__, for example: + +.. code-block:: bash + + git config --global user.signingkey 3AA5C34371567BD2 + git config --global commit.gpgsign true + git config --global gpg.program $(which gpg) + +.. seealso:: + + `Popular git config options `__ + Commit messages ---------------