Improving Git workflow

Felipe Contreras felipe.contreras at gmail.com
Thu Oct 10 00:04:14 CEST 2013


Hi,

I'm a long time Git user and a git.git developer and I've downloaded
Xfce Git repositories, and compiled Xfce a couple of times.

I find it very difficult to navigate through the changes in your
repositories, and I have some suggestions how to improve the
organization.

As an example I'll use xfce4-panel, and to start, I'm going to
concentrate on two branches: master, and xfce-4.10.

To visualize the changes in these two branches and nothing else, I run
this command:

% gitk xfce-4.10...master

I can see that most of the changes are just translation noise, which
right off the bat is not ideal, because there's no easy way to see
what are the actual changes.

So my first proposed change is to have a separate branch for
translations, and continuously merge that branch. I cleaned up the
last commits of the master branch to show how it would look like, and
the advantages, and it would look something like this:

*   6d962c8 (HEAD, master) Merge branch 'l10n'
|\
| * d7e08ed (l10n) I18n: Update translation is (86%).
| * 0cc9b6b I18n: Update translation zh_TW (100%).
| * 882ee9f I18n: Add new translation zh_HK (100%).
| * af0af57 I18n: Update translation it (100%).
| * 90c83c1 I18n: Update translation de (100%).
| * 07a97af I18n: Update translation bg (100%).
| * bf0fe59 I18n: Update translation is (83%).
| * 638aa77 I18n: Update translation es (83%).
| * 5e06be2 I18n: Update translation nl (100%).
| * 43752f2 I18n: Update translation tr (100%).
| * 53b4c46 I18n: Update translation es (76%).
| * 6722d20 I18n: Update translation tr (93%).
| * a70ffd7 I18n: Add new translation hr (58%).
| * 866f1a0 I18n: Update translation zh_CN (100%).
| * 9e6fcd3 I18n: Update translation ar (100%).
| * 63c67b9 I18n: Add new translation uk (100%).
| * dc2d7e0 I18n: Update translation hu (100%).
| * 651dc30 I18n: Update translation pt (100%).
| * 0d68c11 I18n: Update translation en_GB (100%).
| * 992af21 I18n: Update translation th (100%).
| * b53b59a I18n: Update translation pl (99%).
| * 08d2003 I18n: Update translation ru (100%).
| * 6dba504 I18n: Add new translation th (51%).
| * 5d13ef2 I18n: Update translation kk (100%).
| * f253898 I18n: Update translation es (73%).
| * dbc056f I18n: Update translation it (99%).
| * 88bf7da I18n: Update translation es (69%).
| * 7b94d8d I18n: Update translation id (100%).
| * 6f48916 I18n: Update translation es (65%).
| * c561526 I18n: Update translation tr (93%).
| * 9e0010a I18n: Update translation he (100%).
| * ba8eb38 I18n: Update translation fr (100%).
* | 27abc70 Use new GarconGtkMenu.

Now it's clear what commits are translations, and what actual changes,
but it doesn't end there.

Now I can add a query to ignore the commits in the translation branch
(^^l10n) and I get this:

* 6d962c8 (HEAD, master) Merge branch 'l10n'
* 27abc70 Use new GarconGtkMenu.
* 768ec57 Merge branch 'l10n'
* 6d8e9db Bump all glade gtk versions to 2.24.
* bab240b Tasklist: Make middle-click action configurable.
* 19b2b9d Merge branch 'l10n'
* 58a58d6 Directorymenu: Pass path to argument (bug #10270).
* 396e76d Merge branch 'l10n'
* dedf7ed Tasklist: Pushed a patch for #8096 (close a window on middle click)
* b5b5eaf Merge branch 'l10n'
* ac39683 ApplicationsMenu: support for non-square icons and layout fixes
* 7aa1356 ApplicationsMenu: Update the icon in the config dialog
* 141addd Bugfix in icon/pixbuf resizing code.
* e95bed2 Install XfcePanelPlugin properties at once.
* e1d301c Merge branch 'l10n'
* 44790c7 Only use names from the /posix directory.
* 7c4a1d5 Add completion for zoneinfo names.
* 912dc5b Merge branch 'l10n'
* 3a40308 Clock: Improve tooltips, plug leaks and fix glade layout.
* 1b50275 Merge branch 'l10n'
* 4061bc5 Clock plugin: removed a warning message.
* a72c064 Merge branch 'l10n'
* 9a52dee Clock plugin: make the calendar popup modal again.
* 5b64f20 Clock plugin: fix double-click behavior when a command is set.
* db1009d Clock plugin, updated information in tooltips.
* d294527 Clock plugin: removed frame widget from calendar popup.
* cbeffa5 Clock plugin, an attempt to fix random crashes.
* c9f1797 Clock plugin: changed the tooltip text.
* a30dd19 Clock plugin: adjusted defaults.
* 5c47388 Clock plugin: a fix to the previous commit
* 5aecdc1 Clock plugin: added a function to call a system clock config tool
* 7dde421 Clock: fixed the month in the calendar popup.
* b74dcb2 Clock plugin: added a simple timezone selection UI.
* 3219915 Clock plugin: proper timezone support and refactoring.
* 835b619 Added a timezone property to the clock plugin.
* 0fc043d Merge branch 'l10n'
*   91d5118 Merge branch 'andrzejr/clock'
|\
| * 5b90c53 Removed "show-frame" property.
| * ce431a5 Removed frame object and all references to it.
| * c56f5e6 Adding a possibility to close the calendar popup with "Esc"
| * 95af512 Placing a clock widget (with frame) in a toggle button.
* | b4a3330 Merge branch 'l10n'
|/
* 61e06a1 Revert "Hide calendar window on <Esc> or mouse press outside
the popup."
* bd681db Fix icons not probably resizing when requested.
* 2de441d Hide calendar window on <Esc> or mouse press outside the popup.
* c67e286 Merge branch 'l10n'
* babce8f Autotools updates.
* d39d43d Merge branch 'l10n'
* 8470349 Put each window in a new window group.
* 5506cbc Ignore GVarueArray compiler warning.
* e70d783 Merge branch 'l10n'
* 557238f Use G_ENABLE_DEBUG to set fatal messages.
* 82e1205 Merge branch 'l10n'
* 7bdc051 Fixed DnD markers with non-square small items.
* fdd74c3 Merge branch 'l10n'
* 2297551 Tasklist: Remove binding for blinking buttons, no UI for this.
* 7070e3d Merge branch 'l10n'
* f3bab83 Tasklist: Show urgent windows from other workspaces (bug #5167).
* 8f2c885 Clock: Add calendar popup to clock plugin (bug #9034).
* 38cbc6f Actions: Fix logic of session saving (bug #8857).
* 7bc071a Merge branch 'l10n'
* eadbb9b Panel: Emit save signal for plugins.
* 526de30 Merge branch 'l10n'
* 562dbaf Libxfce4-panel: Fix typo in the API docs.
* 45e48c6 Merge branch 'l10n'

Even more, I can do --no-merges:

* 27abc70 Use new GarconGtkMenu.
* 6d8e9db Bump all glade gtk versions to 2.24.
* bab240b Tasklist: Make middle-click action configurable.
* 58a58d6 Directorymenu: Pass path to argument (bug #10270).
* dedf7ed Tasklist: Pushed a patch for #8096 (close a window on middle click)
* ac39683 ApplicationsMenu: support for non-square icons and layout fixes
* 7aa1356 ApplicationsMenu: Update the icon in the config dialog
* 141addd Bugfix in icon/pixbuf resizing code.
* e95bed2 Install XfcePanelPlugin properties at once.
* 44790c7 Only use names from the /posix directory.
* 7c4a1d5 Add completion for zoneinfo names.
* 3a40308 Clock: Improve tooltips, plug leaks and fix glade layout.
* 4061bc5 Clock plugin: removed a warning message.
* 9a52dee Clock plugin: make the calendar popup modal again.
* 5b64f20 Clock plugin: fix double-click behavior when a command is set.
* db1009d Clock plugin, updated information in tooltips.
* d294527 Clock plugin: removed frame widget from calendar popup.
* cbeffa5 Clock plugin, an attempt to fix random crashes.
* c9f1797 Clock plugin: changed the tooltip text.
* a30dd19 Clock plugin: adjusted defaults.
* 5c47388 Clock plugin: a fix to the previous commit
* 5aecdc1 Clock plugin: added a function to call a system clock config tool
* 7dde421 Clock: fixed the month in the calendar popup.
* b74dcb2 Clock plugin: added a simple timezone selection UI.
* 3219915 Clock plugin: proper timezone support and refactoring.
* 835b619 Added a timezone property to the clock plugin.
* 5b90c53 Removed "show-frame" property.
* ce431a5 Removed frame object and all references to it.
* c56f5e6 Adding a possibility to close the calendar popup with "Esc"
* 95af512 Placing a clock widget (with frame) in a toggle button.
* 61e06a1 Revert "Hide calendar window on <Esc> or mouse press outside
the popup."
* bd681db Fix icons not probably resizing when requested.
* 2de441d Hide calendar window on <Esc> or mouse press outside the popup.
* babce8f Autotools updates.
* 8470349 Put each window in a new window group.
* 5506cbc Ignore GVarueArray compiler warning.
* 557238f Use G_ENABLE_DEBUG to set fatal messages.
* 7bdc051 Fixed DnD markers with non-square small items.
* 2297551 Tasklist: Remove binding for blinking buttons, no UI for this.
* f3bab83 Tasklist: Show urgent windows from other workspaces (bug #5167).
* 8f2c885 Clock: Add calendar popup to clock plugin (bug #9034).
* 38cbc6f Actions: Fix logic of session saving (bug #8857).
* eadbb9b Panel: Emit save signal for plugins.
* 562dbaf Libxfce4-panel: Fix typo in the API docs.

Now it's very clear what are the actual changes.

Note that the contents of the commits don't change, at every point in
time the contents of each commit are exactly the same as you have them
now, because the translation branch is constantly merged. In addition,
the translation branch can merge master when it needs to.

If you do this, you would arrive at what actually was worrying me:

* f4e7c27 Post release tag bump.
* 48000a2 (tag: xfce4-panel-4.10.1) Updates for release.
* ef18491 Bugfix in icon/pixbuf resizing code.
* a51135e Fix icons not probably resizing when requested.
* 4294d60 Autotools updates.
* 217e17d Ignore GVarueArray compiler warning.
* 1965297 Use G_ENABLE_DEBUG to set fatal messages.
* eb60ba8 Fixed DnD markers with non-square small items.
* 31f9236 Actions: Fix logic of session saving (bug #8857).
* 6ef607c Panel: Emit save signal for plugins.
* dd5c7fb Libxfce4-panel: Fix typo in the API docs.
* bac9f33 Post release tag bump.

It seems the stable branch is not properly maintained. There's a lot
of good stuff in 'master' that should be backported, so the users
don't have to wait years for the fixes and improvements. But it's
really hard to cherry-pick the good stuff, if you cannot easily see
it.

Secondly, you don't need tags named like xfce4-panel-4.10.0, we are
already in xfce4-panel, there's no need to specify the name again. A
good convention is what git.git does; v4.10.0. Similarly, you don't
need an xfce-4.10 branch, it can be named 4.10.

Third, you don't need personal branches like andrzejr/deskbar2, that's
what personal repositories are for. See for example:

http://cgit.freedesktop.org/~keithp
https://git.kernel.org/cgit/linux/kernel/git/torvalds/

Finally, you don't need to do manual version bumps; autoconf can
determine the version automatically. I can provide patches for that if
you are interested.

This is not some random rant. I'm willing to help you guys in the
transition if you are interested, and even provide scripts if needed.
Also, I can provide the patches for the automatic version bumps.

What do you think?

-- 
Felipe Contreras


More information about the Xfce4-dev mailing list