Answer
$$\int \frac{1-\sec t}{\cos t-1} d t =\sin t-2t+\ln |\sec t+\tan t|+c$$
Work Step by Step
$$
\int \frac{1-\sec t}{\cos t-1} d t
$$
Since
\begin{align*}
\int \frac{1-\sec t}{\cos t-1} d t&=\int \frac{1-\frac{1}{\cos t}}{\cos t-1} d t\\
&=\int \frac{\frac{\cos t-1}{\cos t}}{\cos t-1} d t\\
&=\int \frac{(\cos t-1)^2}{\cos t} d t\\
&=\int \frac{\cos^2 t-2\cos t+1}{\cos t} d t\\
&=\int (\cos t-2+\sec t)dt\\
&=\sin t-2t+\ln |\sec t+\tan t|+c
\end{align*}