Answer
$$ g'(z)=-z^{-2}(z-2)(z^2+1)+z^{-1}(z^2+1)+2(z-2)$$
Work Step by Step
Recall the product rule: $(uv)'=u'v+uv'$
For the sake of simplicity, we rewrite $ g(z)$ as follows
$$ g(z)=z^{-1}(z-2)(z^2+1)$$
Using the product rule, the derivative $ g'(z)$ is given by
$$ g'(z)=-z^{-2}(z-2)(z^2+1)+z^{-1}(z^2+1)+2zz^{-1}(z-2)\\
=-z^{-2}(z-2)(z^2+1)+z^{-1}(z^2+1)+2(z-2)$$