He's trying to fuck you over. Remind him that he works for you, not the other way around. Start looking for his replacement. Check with a lawyer about the security of your own stake and make sure you are good with the business guy, because the CTO has probably been whispering poison in his ear about you.
> .. the CTO has probably been whispering poison in his ear about you. This just has to be true.
"I have improved significantly in the last few months from where I was (generally unstructured development, no tests, poor formatting / naming etc., but functional, generally coding to working with others instead of by myself) but he has said that it's not enough.
We have hired another coder who I get along well with and I have learned from."
There's quite possibly a good argument to be made saying "this guy shouldn't have commit access to our code base" and it's not beyond the bounds of reasonableness to read into that "a few mid level developers under normal CTO oversight will give us a much better starting codebase than this guy is likely to deliver without significant extra training and experience".
Not saying that's definitely the case, but it's certainly plausible. (And I've seen it before, more than once... Hell, I've _been_ "that guy" myself, back in the day.)