1. Config

Contents

    Conditional git profile configuration

    Fonctionnement

    Trois niveaux

    Commandes de base

    → au niveau système, il faut utiliser --system
    → au niveau repository, ne pas mettre de flag spécifique

    Propriétés (souvent global)

    Infos utilisateur
    git config --global user.name "John Doe"
    git config --global user.email johndoe@example.com

    Editeur de texte
    git config --global core.editor emacs
    git config --global core.editor vim

    Alias
    git config --global alias.hist "log --all --graph --decorate --oneline"

    Diff tool

    Merge tool

    gitignore

    # pas de fichier .a
    *.a
    
    # mais suivre lib.a malgré la règle précédente
    !lib.a
    
    # ignorer uniquement le fichier TODO à la racine du projet
    /TODO
    
    # ignorer tous les fichiers dans le répertoire build
    build/
    
    # ignorer doc/notes.txt, mais pas doc/server/arch.txt
    doc/*.txt
    
    # ignorer tous les fichiers .txt sous le répertoire doc/
    doc/**/*.txt
    

    Proudly Powered by Zim 0.75.2.

    Template by Etienne Gandrille, based on ZeroFiveEight and using JQuery Toc Plugin.