Allow resetting a non-Editing branch to a commit

I currently use the workflow described here for managing my published code branch:

  1. Checkout 'published' branch
  2. Find the commit I wanted to put into production.
  3. right click and choose Reset 'published' branch to here

My request is for a way to skip step 1, to right-click on a commit and reset a non-Editing branch to it.

The main problem with requiring step 1 is that it makes ‘published’ the Editing branch. So if I then start editing code in the IDE without remembering to switch back to my development branch, I can too-easily break my production app.


I wonder if there’s a way to do this with git, e.g., in a batch file or other script.

Of course, the target commit might need a special tag, set in the IDE…

Yeah, I expect there is a way to do it from the command line. But I’m one of those that works almost exclusively in the IDE.

Same here, and I’ve broken production in exactly that way, a few times. Briefly.

I agree, that footgun needs a safety.