Attaching cells to homotopy equivalent spaces Suppose $X$ and $Y$ are homotopy equivalent, i.e. there exist $f:X\to Y$ and $g:Y\to X$ whose compositions are homotopic to the identity maps. Take $A\subseteq B$ to be a cofibration and $\phi:A\to X$ some map (everything a CW complex and cellular if you want).
Are the adjunction spaces $X\cup_\phi B$ and $Y\cup_{f\circ\phi} B$ homotopy equivalent? I feel like this should be true but I'm having a little difficulty lining things up.
 A: I hope this proof is sufficiently conceptual (and correct). First consider the cylinder space $\textrm{Cyl}(\phi)$ it is homotopy equivalent to $X.$ Moreover, we have a homotopy equivalence $X\cup_\phi B\simeq B\cup_\phi \textrm{Cyl}(\phi).$ This homotopy equivalence comes from contracting "shaft" of the cylinder.
We also have an induced map $\hat{f}:\textrm{Cyl}(\phi)\to Y.$ This map is given on $X$ by $f$ and on $A$ by $f\circ\phi.$
Now we can take another cylinder $\textrm{Cyl}(\hat{f}).$ The map $\hat{f}:\textrm{Cyl}(\phi)\to \textrm{Cyl}(\hat{f})$ becomes a cofibration. We once again have a homotopy equivalence $Y\cup_{f\circ \phi} B\simeq \textrm{Cyl}(\hat{f})\cup_\phi B.$
Now here is were the heavy artillery comes in. Since $\hat{f}\circ\phi$ and $A\subseteq B$ are cofibration the projection lemma for homotopy colimits (see for example this article) implies that $$\textrm{colim}(B \leftarrow A \to \textrm{Cyl}(\hat{f}))\simeq \textrm{hocolim}(B \leftarrow A \to \textrm{Cyl}(\hat{f})).$$
It remains to note that since $\textrm{hocolim}$ is homotopy invariant we have homotopy equivalences:
$$
Y\cup_{f\circ \phi} B\simeq \textrm{Cyl}(\hat{f})\cup_{\hat{f}\circ\phi} B \simeq \textrm{Cyl}(\phi)\cup_\phi B\simeq X\cup_\phi B.
$$
