AliSplit: rewritehist acts on "local" branches

Instead of changing the local copy of remotes/origin,
reference every remote branch locally (refs/heads/*) without
checking it out (i.e. without changing the working directory)
and act on the local copies only. The final result can be
either force-pushed on "origin", or pushed to a brand-new
remote.