Suppose $0 \to M \to N \to R \to 0$ is a short exact sequence of $R$-modules for a nice ring $R$. The Horseshoe lemma allows us to create a projective resolution of $N$ by using projective resolutions of $M$ and $R$.
My question is this
Is it possible to generate a projective resolution of $R$ using that of $M$ and $N$?
This question arising from p. 156 of Matsumura's Commutative Ring Theory. In the book, the author claims that
Taking a minimal $B$-projective resolution of $\mathfrak m / x A$ and patching it together with the exact sequence $0 \rightarrow \mathfrak{m} / x A \longrightarrow B \longrightarrow k \rightarrow 0$ gives a projective resolution of $k$ of length $\leqslant r+1$.
However I do not understand how the author got this projective resolution.
The horseshoe lemma is not at play here - what Matsumura is saying is that if $P^\bullet\to m/xA\to 0$ is a $B$-projective resolution of $m/xA$, then $P^\bullet\to B\to k\to 0$ is a $B$-projective resolution of $k$, which has length $\operatorname{length}(P^\bullet)+1$.