[notmuch] JSON based emacs UI

Michal Sojka sojkam1 at fel.cvut.cz
Mon Mar 29 02:03:05 PDT 2010


On Mon, 29 Mar 2010, Sebastian Spaeth wrote:
> On Sun, 28 Mar 2010 07:46:40 +0200, Michal Sojka <sojkam1 at fel.cvut.cz> wrote:
> > I don't think this can be solved only in Makefile. From my look at dme's
> > repo, he adds a new subcomand 'part', which is used by the UI. So if you
> > want to use the new UI and your other features, you need to merge the
> > things together.
> 
> I agree that notmuch and notmuch.el need to be developed deployed in
> close cooperation. However, this bundling makes things a bit more
> complex to untangle. I am willing to e.g. add the -part improvement to
> my own branch of notmuch, but I want to follow dme's frontend closely.
> 
> > To build my version of notmuch, I use an ugly script
> > (http://rtime.felk.cvut.cz/gitweb/notmuch.git/blob/refs/heads/debian-wsh:/wsh-buildpackage)
> > which first does a big octopus merge to combine several features to one
> > branch and then I build notmuch from there. The current state of my
> > integration can be seen at
> > http://rtime.felk.cvut.cz/gitweb/notmuch.git/shortlog/refs/heads/integration/features.
> 
> Interesting, but a bit more complicated that I was originally thinking off.
> 
> > This approach has a disadvantage that integration/features branch is
> > often rewritten (whenever I add, remove or change a patch) so that
> > others cannot track the branch. On the other side, the advantage is that
> > others can easily see which patches I have applied on top of master. If
> > Carl updates master, I just rerun the script and the updated integration
> > branch is ready (unless there is a merge conflict).
> 
> Very nice.

Here is a simplified version of my script. It does only the merge. If
you want to use it, I recommend adding this script to a separate branch
so that you can track which branched were added or removed to your
features branch (you will modify the $branches variable in the script).

#!/bin/sh

branches="
decode-headers-in-reply
dme/citation-suffixes
no-self-bcc-on-reply
"

set -e

die()
{
	echo >&2 "fatal: $*"
	exit 1
}

if [ -z "$EXEC_OK" ]; then
    # If this script is tracked by repository, checking out another
    # branch could delete it so we copy it to tmp and run it from
    # there.
    script=$(mktemp -t notmuch-integrate.XXXXXX)
    cp "$0" "$script"
    EXEC_OK=1
    export EXEC_OK
    exec sh "$script" "$@"
fi

[ $EXEC_OK != 1 ] && die "Error: something went wrong"

trap "rm '$0'" EXIT

git branch -D integration/features || :
git checkout -b integration/features master
git merge $branches


More information about the notmuch mailing list