I am trying formally derive the projection of the energy eiegenstates of the 1D quantum harmonic oscillator into the $x$ basis $$ \phi_n(x) = \langle x | n \rangle = \langle x | \frac{{a^{\dagger}}^{n}}{\sqrt{n!}} | 0 \rangle = \frac{{a^{\dagger}}^{n}}{\sqrt{n!}} \, \phi_0(x) $$
I'm not sure how to make the last step
$$ \langle x |\frac{{a^{\dagger}}^{n}}{\sqrt{n!}} | 0 \rangle = \frac{{a^{\dagger}}^{n}(x)}{\sqrt{n!}} \langle x | 0 \rangle $$
where I use ${a^{\dagger}}^{n}(x)$ to clarify that the operator is in the $x$ basis.
I feel I need to use the resolution of identity
$$ \int \langle x | \frac{{a^{\dagger}}^{n}}{\sqrt{n!}}| x' \rangle \langle x'| 0 \rangle \: \mathrm{d} x'$$
I can do this integral for a single creation operator
$$ \int \langle x | a^{\dagger}| x' \rangle \langle x'| 0 \rangle \: \mathrm{d} x' = \int \langle x | \gamma X - i \epsilon P| x' \rangle \langle x'| 0 \rangle \: \mathrm{d} x' $$
where $ \gamma = \sqrt{\frac{m \omega}{2 \hbar}}$ and $ \epsilon = \sqrt{\frac{1}{2m \omega \hbar}}$. Using the matrix representations of the $X$ and $P$ operators in the $x$ basis
$$ \langle x |\gamma X - i \epsilon P| x' \rangle = x' \gamma \delta(x - x') + \hbar \epsilon\delta^{(1)}(x - x')$$
where $\delta^{(1)}(x)$ is the first derivative of the Dirac delta function. So the integral is
$$ \phi_1(x) = \int \left[ x' \gamma \delta(x - x') + \hbar \epsilon\delta^{(1)}(x - x') \right] \phi_0 (x') \: \mathrm{d} x' = \left[ \gamma x - \hbar \epsilon\frac{\mathrm{d}}{\mathrm{d} x} \right]\phi_0 (x)$$
So how do I continue with this derivation? Do I make some sort of inductive step? Is this even the right path to go down, is there a much simpler method?