Complex integral of an exponent divided by a linear ($\int \frac{e^u}{u-1}$) Here is the question I'm working on:

Evaluate the following integral:

$$ \oint_{|z+1|=1} \frac{\sin \frac{\pi z}{4}}{z^2-1}dz$$

I've tried along the following line. Substitute $sin(z) = \frac{e^z-e^{-z}}{2i}$:

$$ \frac{1}{2i} \int \frac{e^{\pi z/4}-e^{-\pi z/4}}{z^2-1}dz$$
The contour is a circle of radius 1 around $-1$, so substitute $z=-1+e^{it}$, with $dz = ie^{it}dt$:
$$ \frac{1}{2i} \int_0^{2\pi} \cfrac{e^{\pi/4(e^{it}-1)}-e^{-\pi/4(e^{it}-1)}}{(e^{it}-1)^2-1}ie^{it}dt = \frac{1}{2} \int \cfrac{e^{\pi/4(e^{it}-1)}-e^{-\pi/4(e^{it}-1)}}{e^{it}-2}dt$$
A repeat of the same substitution $u = e^{it} - 1$ with $du = ie^{it}dt$ gives:
$$\frac{1}{2} \int \cfrac{e^{\pi u/4}-e^{-\pi u/4}}{u-1}du$$
At this point I've run out of ideas. Any hint or pointer would be appreciated.

Use the Residue Theorem:
$$\oint\limits_{|z+1|=1}\frac{\sin\frac{\pi z}4}{z^2-1}dz=\frac12\left(\overbrace{\oint\limits_{|z+1|=1}\frac{\sin\frac{\pi z}4}{z-1}dz}^{=0}-\oint\limits_{|z+1|=1}\frac{\sin\frac{\pi z}4}{z+1}dz\right)=$$
$$=\left.-\frac{2\pi i}2\sin\frac{\pi z}4\right|_{z=-1}=\frac{\pi i}{\sqrt2}$$
