Hi,
I've been thinking about the following feature request for a while, but I wanted to share/exchange some thoughts first here on the list.
When pushing your changes for review to any of the special remote refs (refs/for/*), it is always reported to be a completely new branch (and you cannot fetch from it). I see the point for this special ref, but my suggestion here is that we advertise the current branch' tip there, as if it's refs/heads/*. I presume it would help the Git client to ...:
- understand what would have been pushed with a dry-run (git push -n).
Currently, a dry-run push is not functional with a special ref. You don't know upfront what commits would become a change in Gerrit. Accidentally pushing to the wrong special ref might create huge amounts of changes (only limited by receive.maxBatchChanges). Having the output of a dry-run push allows a user to prevent errors. - report a push of outdated changes before it's created a change in Gerrit.
Refuse a non-fast-forward update just like pushing to refs/heads/*. This would avoid unnecessary rebase patch sets if the user sees it later in the UI (might even see a Merge Conflict status directly after push).
(To not break current functionality, we could allow force pushing to still allow creating outdated changes.)
So, currently, I see only wins by implementing this, yet breaking the current behaviour a bit.
Would this be a valid feature request or am I asking something impossible?
Thanks,
Gert