As I said, most people believe this, but rarely is it the case IME. It's always possible you're an exception (as I said before).
Simplest answer is this. As a player and DM I make a conscious effort when creating my PC's. NPC, selecting monsters for encounters that there are multiple options from round to round, so combats don't get repetitive. Am I always successful obviously not, There's more things to do in an encounter than just attack.
How often do you do those things in each combat? It is about the overall feel for what you do, not in a single combat.
But, it is still attack, attack, attack (which is understandable and the point as I said upthread).
Perhaps my definition of doing the same thing in a combat, or over the course of PCs career is different than yours. If I'm mixing up using different melee weapons, spells, etc, that's not doing the same thing IMO. Doing the same thing to me would be spamming the same cantrip or constantly using the same weapon all combat, every combat. Lets say a creature has one attack per its stat block. It can do the same attack every round until its dead, or it can take a round to reposition itself, flee to ambush later, stop fighting and parlay, hide, surrender, etc. As long as the encounter is fluid there are many more options to explore than just two combatants exchanging attacks until one is dead.
How many rounds do you attack with a spell or your mace?
In 7 levels of play I attacked with my mace 732 times and cast 401 spells. All kidding aside, I honestly don't know. Did I use my mace in 2 consecutive rounds ever, you bet I Did.
So, you're in combat, fighting for your life, and you don't want to do the most effective thing to defeat your enemy?
I didnt say that but sometimes dealing one more round of damage is the lesser option. As was the case here, instead of reducing the enemy by a few more hit points, I incapacitated him, giving the option for players to get free shots on him and eventually killing him.
It isn't about min-maxing, but effectiveness. Grab a marlin and making an attack without proficiency (unless you had Tavern Brawler... you were in a tavern, after all) and you somehow managed to "pin" your foe to a wall?
I'd say it was quite effective. Regardless, I'd don't think any of us at the table cared that there was a tavern brawler feat, and no I didnt have it. I told the DM what I wanted to do, rolled and succeeded in my improvised attack. My DM had the common sense not to let some fiddly rule get in the way of a good idea and let it succeed.
I asked if you aren't playing a spellcaster, what would you do?
I did quote your message, but sorry I misread it. If I wasn't playing a spell caster, I'd try to utilize the abilities granted by the class in a non-repetitive way.