I'm trying to prove the following result, however I'm very much struggling to understand some of the finer details of the proof. Would someone be able to explain it to me? It's definitely a standard result, but my textbooks are very vague about the derivation.
Lemma: If \begin{align} \label{eq:homo_PDE} \frac{\partial u}{\partial t} = \frac{1}{\kappa}\frac{\partial^2 u}{\partial x^2} ,\quad x\in(-\infty,\infty) \end{align} and \begin{align} u=f(x),&\quad\text{when}\ t=0\\ u\rightarrow 0,\quad &\text{as}\ \ |x|\rightarrow\infty,\quad\forall t\geq0 \end{align} then it has the following solution \begin{align} \label{eq:heat_kernal} u = \frac{1}{2\sqrt{\pi\kappa t}} \int_{-\infty}^{\infty} f(x') e^{-(x-x')^2/4\kappa t}\ \text{d}x' \end{align}
First point : Green's function
The Green's function of heat equation is the solution $u$ when $f(x)$ is a Dirac delta function $\delta(x)$. Let us denote it by $g$. In the case of the heat equation it is known that $$g(x,t)=\frac{1}{\sqrt{4\pi\kappa t}}\exp\left(-\frac{x^2}{4\kappa t}\right).$$ To prove this, first remark that $$\frac{\partial g}{\partial t}(x,t)=-\frac1{2t}g(x,t)+\frac{x^2}{4\kappa t^2}g(x,t)$$ and that $$\frac{\partial^2 g}{\partial x^2}(x,t)=\frac{\partial}{\partial x}\left(-\frac{x}{2\kappa t}g(x,t)\right)=-\frac{1}{2\kappa t}g(x,t)+\frac{x^2}{4\kappa^2t^2}g(x,t).$$ We remark immediately that $\frac{\partial g}{\partial t}(x,t)=\kappa\frac{\partial^2 g}{\partial x^2}(x,t)$ (this is not quite what you wrote in your question, since you have written $\frac1\kappa$ instead of $\kappa$). To prove that $g(x,0)=\delta(x)$, one needs to use Fourier transforms as @Cameron wrote.
Second point : convolution
Now the initial condition if $u(x,0)=f(x)$. The solution is obtained by convolution of $f$ with $g$, as you have written. Observe that if we use the derivation operators on $u$ we obtain $$\frac{\partial u}{\partial t}(x,t)=\int_{\mathbf R}f(x')\frac{\partial g}{\partial t}(x-x',t)\mathrm dx'=\kappa \int_{\mathbf R}f(x')\frac{\partial^2 g}{\partial^2 x}(x-x',t)\mathrm dx'= \kappa \frac{\partial^2 u}{\partial^2 x}(x,t).$$ Therefore $u$ is the solution of the heat equation. Its initial condition is $$u(x,0)=\int_{\mathbf R}f(x')\delta(x-x')\mathrm dx'=f(x).$$