You could put a 'git-svn' binary in your path ahead of the real
git-svn that examines the current world and errors out if necessary,
or otherwise calls the real one. But note that git cl dcommit shells
out to git svn as well, so you'd need to hack around that.
> --
> Chromium Developers mailing list: chromi...@chromium.org
> View archives, change email options, or unsubscribe:
> http://groups.google.com/a/chromium.org/group/chromium-dev
Idea1: if git-svn had a precommit hook, you could make the hook check
for an environment variable, and then have git-cl set that environment
variable when shelling out to git-svn. Unfortunately git-svn appears
to not support any hooks, maybe you could add them.
Idea2: maybe you could put something in your PATH that *shadows* the
real git-svn, then do the same environment hack to let git-cl through.
Shell alias? Something like (pseudocode):
function git() {
if $1 == "svn" and $2 == "dcommit"; then
\git cl dcommit "rest of args (perhaps $@ after shifting out the
first two)"
else
\git "$@"
fi
}
}