Créez et appliquez des correctifs

Les correctifs sont des instructions de réécriture que Git peut appliquer à un ensemble de fichiers.

Pour générer des fichiers de correctifs à partir de commits locaux :

  1. Accédez à Tools > Git > Local Repository.
  2. Sélectionnez « Patch » > « Create from Commits ».
  3. Sélectionnez les commits pour la création des fichiers de correctifs dans la boîte de dialogue.
  4. Sélectionnez « OK ».

Les fichiers de correctifs sont générés dans le répertoire racine du dépôt local et suivent le schéma NNNN-Titre-du-commit.patch, où NNNN est un nombre à quatre chiffres commençant par 0000.

Pour appliquer un fichier de correctif ouvert dans « Qt Creator », accédez à « Tools » > « Git » > « Local Repository », puis sélectionnez « Patch » > « Apply from Editor ».

Pour sélectionner le fichier de correctif à appliquer à partir du système de fichiers, sélectionnez « Apply from File ».

Pour appliquer un patch à partir du presse-papiers, sélectionnez « Apply from Clipboard ».

Voir aussi «Comment : utiliser Git » et « Utilisation de Git ».

Copyright © The Qt Company Ltd. and other contributors. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.