This problem looks like that for evaluating Fresnel integrals, but we have to understand the nature of how it converges. For this, we turn to Cauchy's theorem. Here, consider
$$\oint_C dz \, e^{-\gamma z^2} $$
where $\gamma = \alpha + i \beta$ and $C$ is a circular sector in the complex plane, centered at the origin, of radius $R$ and having a wedge angle of $\theta_0 = \frac12 \arctan{(\beta/\alpha)}$ below the real axis. Of course it is assumed that $\alpha \gt 0$.
The above contour integral is equal to
$$\int_0^R dx \, e^{-\gamma x^2} + i R \int_0^{-\theta_0} d\theta \, e^{i \theta} \, e^{-\gamma R^2 e^{i 2 \theta}} + e^{-i \theta_0} \int_R^0 \, dt \, e^{-\gamma e^{-i 2 \theta_0} t^2} = 0$$
To show that the second integral vanishes as $R \to \infty$, we note that $\gamma e^{i 2 \theta} = |\gamma| e^{i 2 (\theta+\theta_0)} $. Accordingly, the magnitude of the second integral takes the form
$$ R \int_0^{\theta_0} d\theta \, e^{-|\gamma| R^2 \cos{(2 \theta_0-2 \theta)}} \le R e^{-|\gamma| \cos{(2 \theta_0)} R^2} \int_0^{\theta_0} d\theta e^{-|\gamma| R^2 \sin{(2 \theta_0)} (4 \theta/\pi)}$$
The latter approximation uses the fact that $\cos{(2 \theta)} \le 1$ and $\sin{(2 \theta)} \le 4 \theta/\pi$ in the integration interval. Thus, the magnitude of the second integral is bounded by $e^{-|\gamma| \cos{(2 \theta_0)} R^2} \frac{\pi}{4 |\gamma| R^2 \sin{(2 \theta_0)}}$, which clearly vanishes as $R \to \infty$.
Thus, we are left with
$$\int_0^{\infty} dx \, e^{-\gamma x^2} =
e^{-i \theta_0} \int_0^{\infty} \, dt \, e^{-|\gamma| t^2} $$
because $\gamma e^{-i 2 \theta_0} = |\gamma|$. Therefore,
$$\int_{-\infty}^{\infty} dx \, e^{-\gamma x^2} = e^{-i \theta_0}\sqrt{\frac{\pi}{|\gamma|}} = \sqrt{\frac{\pi}{\gamma}}$$
as was to be shown.