A big piece of the problem with Archer and never-endingly recurring question of how he obtain command of the NX-01 is we never find out what he was doing between the time he was a test pilot and the show's first episode.
Some fans have conjectured that it was it was his father's name and a personal friendship with Forrest that placed Archer in the captain's seat. Some backstory of servicing on another starship (they do have them), rising to first officer of one, or a prior extra-solar exploration mission with one would give Archer the credentials to be captain of his own starship.
I understand from interviews with the producers that they initially wanted to have the first season more like "First Flight" -- showing how the crew was put together, testing the ship, etc. etc. But the suits didn't go for it; they were afraid it would be too "different". (Considering the reaction from some fans about DS9, they had a somewhat valid point.) I would have watched, though. And it might have explained why Archer, flaws and all, made it to the centre seat.
I don't mind the character as much as some other people do. It's somewhat of a mystery to me, though, how Scott Bakula, who is such a lovely and charming gentleman, ended up playing Archer this way. The few times I've watched NCIS: New Orleans, his take on a leader is totally different.
And Trip starts out as a bit of an ass, but by series' end he is an accomplished commander. On the TWoP forums, there was a lot of talk about making Trip captain, and the general consensus is that he would be awesome.
I haven't read any of the "Federation Rising" books (I don't like the idea of (a) Trip away from the crew; and (b) a Section 31 operative) even though I appreciate the attempt at a reboot of The Abomination, so I don't know how he's portrayed in that series.