The assumption of linearity is based on the observation that measurement results between reference frames depend only on their relative motion, not their absolute position (which doesn't exist anyway). The derivation is a bit involved, so I can understand why it was glossed over. Good on you for noticing the gloss.
In general, we start with
$$x' = F(x,t; a)$$
where $F$ is an unknown functions of position ($x$), time ($t$), and some as yet unknown parameter ($a$). There's an entire other argument as to why there's only one parameter.
Let's look at how $x'$ changes with $x$ and $t$:
$$dx'= \frac{\partial F}{\partial x}dx + \frac{\partial F}{\partial t}dt.$$
Here's where relativity comes in: the laws of physics and our measurements don't seem to depend on position in some absolute, universal coordinate system, nor on time as measured from some universal starting point. This leads to the conclusion that $\frac{\partial F}{\partial x}$ and $\frac{\partial F}{\partial t}$ cannot depend on $x$ and $t$. Thus (with a minus sign for future convenience),
$$\frac{\partial F}{\partial x} = H(a)$$
$$\frac{\partial F}{\partial t} = -K(a)$$
where $H$ and $K$ are two yet-to-be-determined functions of the unknown parameter $a$.
Thus, $F$ is a linear function in $x$ and $t$. We can write this as
$$x' = H(a)x - K(a)t$$
A little rearranging:
$$x' = H(a)\left(x - \frac{K(a)}{H(a)}t\right)$$
Just looking at the units, $\frac{K(a)}{H(a)}$ must be a velocity. To find this velocity, let's put a particle at rest in the origin of the primed frame: $x' = 0$.
$$0 = H(a)\left(x - \frac{K(a)}{H(a)}t\right)$$
$$x = \frac{K(a)}{H(a)}t$$
We also know that this particle is moving with velocity $v$ in the unprimed system:
$$x = vt.$$
Thus,
$$\frac{K(a)}{H(a)} = v.$$
We can also conclude (not definitively, but suggestively) that the unknown parameter $a$ is $v$.
With a suitable rewriting of variables ($H \rightarrow \gamma$, $a \rightarrow v$):
$$x' = \gamma(v)(x-vt)$$
The derivation of
$$\gamma(v) = \frac{1}{\sqrt{1-\frac{v^2}{c^2}}}$$
continues from here.
The above is shamelessly stolen from Jean-Marc Lévy-Leblond's One More Derivation of the Lorentz Transformation. I like this paper because it doesn't assume the constancy of the speed of light. This fact is actually derivable from some very general and safe assumptions of how space and time work. In fact, in a universe with a massive photon (i.e., in which nothing could reach the now misnamed "speed of light"), this derivation would still work. It's a longer, subtler, and more involved derivation, so I can see why it's not used in classrooms. But, it's a bit wild to think that anyone from Newton on (or Galileo with some pseudo-calculus) could have discovered the Lorentz transform.