$i : X^{n} \hookrightarrow X$ is a cofibration I'd like to understand why is $X$ is $CW$ complex $i : X^{n} \hookrightarrow X$ is a cofibration when the dimension of $X$ is not finite. The proof I'd like to generalize:
I'm going to use $\bigsqcup \mathbb{S}_{\lambda}^n \hookrightarrow \bigsqcup \mathbb{D}_{\lambda}^n$ that is a cofibration. Then using that the following is a pushout diagram and the cofibration $\bigsqcup \mathbb{S}_{\lambda}^n \hookrightarrow \bigsqcup \mathbb{D}_{\lambda}^n$
$$\begin{array}{ccccccccc}
 \bigsqcup \mathbb{S}_{\lambda}^n  & \overset{}{\hookrightarrow} &\bigsqcup\mathbb{D}_{\lambda}^n\\\
\downarrow{} & & \downarrow{} & \\\
X^{n-1} & \overset{}{\rightarrow} & X^{n} 
\end{array}$$
we have that $X^n \hookrightarrow X^{m}$ is a cofibration whenever $n \geq m$, which concludes the proof if $X$ has finite dimension.
I'd like to extend this "process" to the following diagram
$$\begin{array}{ccccccccc}
 \bigsqcup \mathbb{S}_{\lambda}^n  & \overset{}{\hookrightarrow} &\bigsqcup\mathbb{D}_{\lambda}^n\\\
\downarrow{} & & \downarrow{} & \\\
X^{n-1} & \overset{}{\rightarrow} & X 
\end{array}$$
But I don't whether the same argument could be applied, since if has no finite dimension it's defined as a colimit. There's a direct generalization of this proof?
Any help or reference would be appreciated.
 A: Well, if you have handled the finite case, now you are left with "taking the colimit", exactly as you mentioned!
More generally, suppose that $f_k: Y \to Z_k$ is a family of cofibrations cofibration, where $\{Z_k\}_{k \in \mathbb{N}}$ is a diagram $Z_1 \to Z_2 \to Z_3 \to \ldots$ made of cofibrations. Suppose also that $f_k$ are consistent with maps $Z_k \to Z_{k+1}$,and set $Z = \textrm{colim} Z_k$. Then $f =  (Z_1 \to Z) f_1$ is a cofibration. You will use $Y=X_n$ and $Z_k = X_{n+k}$ to recover the result in your case. Note that the hypothesis holds true because of what you showed in the finite case.
The proof is very general and holds for any model category, if you know what they are. Indeed, if you want to know whether a map is a cofibration, you have to check if it has the left lifting property against all fibrations. I suggest you make diagrams yourself to follow the proof.
Let $U \to V$ be a fibration, and let $Y \to U, Z \to V$ maps so that the square $Y, U, Z, V$ commutes. We want to know if there exist a diagonal map - a "lifting" - from $Z$ to $U$ that makes the two triangles commute. Restrict the square to $Y, Z_1, U, V$. Since $Y \to Z_1$ is a cofibration, you can find a map $Z_1 \to U$ that makes the triangles commute. Now construct a square $Z_1, U, Z_2, V$. Since $Z_1 \to Z_2$ is a cofibration, you can extend the map $Z_1 \to U$ to a map $Z_2 \to U$. Continuing in this fashion, you get maps $Z_k \to U$ that commutes with the diagram maps $Z_n \to Z_{n+1}$ and that correctly restrict to $Y$. Taking the colimit of such maps you get your desired lifting $Z \to U$, and you are done.
