Age | Commit message (Collapse) | Author | |
---|---|---|---|
2022-03-29 | gitattributes: Cover Objective-C source files | Philippe Mathieu-Daudé | |
Apple's Git distribution actually carries a similar file which annotates *.m: https://github.com/apple-opensource/Git/blob/73/gitattributes See comments in commit 29cf16db23 ("buildsys: Help git-diff adding .gitattributes config file") for details. Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Christian Schoenebeck <qemu_oss@crudebyte.com> Message-Id: <20220317130326.39188-1-philippe.mathieu.daude@gmail.com> | |||
2021-02-15 | maint: Tell git that *.py files should use python diff hunks | Eric Blake | |
Git's default hunk pattern recognizer favors the C language, but it also includes several built-in diff styles that give saner results in other languages. In particular, telling git to treat all .py files as python changes the beginning of diff hunks as follows: | --- a/python/qemu/machine.py | +++ b/python/qemu/machine.py | -@@ -337,12 +337,12 @@ class QEMUMachine: | +@@ -337,12 +337,12 @@ def _post_shutdown(self) -> None: | self._qmp.close() which makes it much easier to tell what function a patch is touching, rather than a non-descript listing of what class contains the changes. Sadly, our python files that don't use .py suffix (such as numerous iotests) do not benefit from this glob. Reported-by: John Snow <jsnow@redhat.com> Signed-off-by: Eric Blake <eblake@redhat.com> Message-Id: <20210215222524.1820223-1-eblake@redhat.com> Reviewed-by: John Snow <jsnow@redhat.com> Reviewed-by: Cleber Rosa <crosa@redhat.com> Signed-off-by: Cleber Rosa <crosa@redhat.com> | |||
2020-11-18 | buildsys: Help git-diff adding .gitattributes config file | Philippe Mathieu-Daudé | |
Since commits 0979ed017f0 ("meson: rename .inc.h files to .h.inc") and 139c1837db7 ("meson: rename included C source files to .c.inc") 'git-diff --function-context' stopped displaying C function context correctly. We can help git-diff by providing attributes to the .[ch].inc path names. See: https://git-scm.com/docs/gitattributes#_generating_diff_text Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20201014082209.3712625-1-philmd@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> |