My book is telling me that I have to complete the square
$I=\begin{eqnarray*} \int \frac{dx}{x^{2}-2x} &=&\int \frac{dx}{\left( x-1\right) ^{2}-1}\overset{ u=x-1}{=}\int \frac{1}{u^{2}-1}\,du=-\text{arctanh }u+C \end{eqnarray*},$ $\tag{1}$
where I have used the substitution $u=x-1$ and the standard derivative $\frac{d}{du}\text {arctanh}=\frac{1}{1-u^{2}}\tag{2}$
You just need to substitute $u=x-1$ to write $\text{arctanh }u$ in terms of $x$.
Added 2: Remark. If we use the logarithmic representation of the inverse hyperbolic function $\text{arctanh }u$ $\begin{equation*} \text{arctanh }u=\frac{1}{2}\ln \left( u+1\right) -\frac{1}{2}\ln \left( 1-u\right),\qquad (\text{real for }|u|<1)\tag{3} \end{equation*}$ we get for $u=x−1 $ $\begin{eqnarray*} I &=&-\text{arctanh }u+C=-\text{arctanh }\left( x-1\right) +C \\ &=&-\frac{1}{2}\ln x+\frac{1}{2}\ln \left( 2-x\right) +C \\ &=&\frac{1}{2}\left( \ln \frac{2-x}{x}\right) +C\qquad (0
Added. If your book does require using partial fractions then you can proceed as follows $\begin{equation*} \int \frac{1}{u^{2}-1}\,du=\int \frac{1}{\left( u-1\right) \left( u+1\right) }\,du=\int \frac{1}{2\left( u-1\right) }-\frac{1}{2\left( u+1\right) }du. \end{equation*}$ $\tag{5}$