[Xcb] [PATCH 3/3] Add note on pretty patches and src/.gitattributes
Daniel Martin
consume.noise at gmail.com
Fri Oct 11 09:18:39 PDT 2013
Add a note to doc/xml-xcb.txt on howto to generate pretty patches and
add src/.gitattributes, which is necessary for that.
Signed-off-by: Daniel Martin <consume.noise at gmail.com>
---
I've had this in my queue for ages. Finally, it made it to the list.
doc/xml-xcb.txt | 19 +++++++++++++++++++
src/.gitattributes | 1 +
2 files changed, 20 insertions(+)
create mode 100644 src/.gitattributes
diff --git a/doc/xml-xcb.txt b/doc/xml-xcb.txt
index 7311911..b172e4c 100644
--- a/doc/xml-xcb.txt
+++ b/doc/xml-xcb.txt
@@ -22,6 +22,25 @@ Generating C bindings
See libxcb <http://cgit.freedesktop.org/xcb/libxcb/>.
+Development
+===========
+
+To send pretty patches add those 2 lines to .git/config:
+
+---------- 8< ----------
+[diff "xcb"]
+ xfuncname = "(<\\b(xcb|enum|event|request|struct|union)\\b.*>)"
+---------- >8 ----------
+
+As all src/*.xml files are tagged as "xcb" (see src/.gitattributes) the
+result of this configuration will be visible at the "@@ -..., +... @@"
+lines of a diff.
+
+An example:
+- without: @@ -1227,6 +1227,8 @@ authorization from the authors.
+- with : @@ -1227,6 +1227,8 @@ <struct name="HierarchyChange">
+
+
Protocol Description Format
===========================
diff --git a/src/.gitattributes b/src/.gitattributes
new file mode 100644
index 0000000..8d345b0
--- /dev/null
+++ b/src/.gitattributes
@@ -0,0 +1 @@
+*.xml diff=xcb
--
1.8.4
More information about the Xcb
mailing list