No, it does not work that way. There are two things you need to control: the behaviour on $[-M,M]\backslash(-\varepsilon, \varepsilon)$ and the behaviour on $ (-\varepsilon, \varepsilon)$. Your reasoning covers the first part. For the second part you need to look closely at $g^\prime(0)$ (and start out with bigger slope than that value). Also, for the first part, the mean value theorem does not seem to be of optimal choice. You are better off to compare with $\max{g}$ instead of $\max{g^\prime}$ on on $[-M,M]\backslash(-\varepsilon, \varepsilon)$.
And no, you can't do without using the derivative of $g$. Use $\sqrt{|x|}$ as a counterexample.
Edit more precisely, you you only need $g$ to be 'better' than continous at the origin. Either the requirement "$g^\prime$ exists at $x=0$" or "$g$ is Lipshitz continuous near the origin" (together with global boundedness or continuity) will do.
Second Edit, in response to a comment, to cover the case $x=0$ under the assumption that $g$ is differentiable in $x=0$.
$g$ being differentiable in $x= 0$ means (taking into account $g(0)=0$) that
$$g(s)=g(0)+g^\prime(0)s+ r(s) = g^\prime(0)s + r(s)$$
where $r(s)$ is a function with the property
$$\lim_{s\rightarrow 0} \frac{r(s)}{s}=0$$
This latter property implies that, for any $\eta >0$ there is $\delta < 0 $such that $|r(s)| < \eta |s|$ for $|s|< \delta$.
So for sufficiently small $s$
$$g(s)= g^\prime(0)s + r(s) \le (g^\prime(0)+\eta)s $$
You may choose $\eta=1$, if you like.
(I used $\eta$ since $\varepsilon$ is in use already).