Suppose you travel an infinitesimal distance $\mathrm ds$ in direction $\alpha$, where $\alpha=0°$ is north and $\alpha=90°$ is east. Then in a tangential coordinate system, you will travel a distance $\mathrm ds\cdot\sin\alpha$ in the eastward-pointing $x$ direction, and a distance $\mathrm ds\cdot\cos\alpha$ in the northward-pointing $y$ direction. Written together:
$\begin{pmatrix}\mathrm dx\\\mathrm dy\end{pmatrix} = \mathrm ds\cdot\begin{pmatrix}\sin\alpha\\\cos\alpha\end{pmatrix}$
Now we want to relate this into changes in latitude $\phi$ and longitude $\lambda$. Multiplying latitude, measured in radians, by $R$, the radius of the sphere and hence the radius of a great circle, you obtain the displacement in $y$ direction. For longitude, you also have to multiply by $\cos\phi$ to obtain the radius of the parallel at latitude $\phi$. So you get
$\begin{pmatrix}\mathrm dx\\\mathrm dy\end{pmatrix} = \mathrm ds\cdot\begin{pmatrix}\sin\alpha\\\cos\alpha\end{pmatrix} = R\cdot\begin{pmatrix} \cos\phi\cdot\mathrm d\lambda \\ \mathrm d\phi \end{pmatrix}$
Now you can start to integrate these infinitesimal steps. Integrating latitudes is easy, since the integrand does not depend on the current position:
$\phi(t) = \phi_0+\int_0^t\frac{\cos\alpha}R\,\mathrm ds = \phi_0 + \frac tR\cos\alpha$
Doing the same for longitudes is more tricky, but since you can plug in this expression for $\phi$, it is possible:
$\lambda(t) = \lambda_0 + \int_0^t\frac{\sin\alpha}{R\cdot\cos\big(\phi(s)\big)}\,\mathrm ds = \lambda_0 + \int_0^t\frac{\sin\alpha}{R\cdot\cos\big(\phi_0+\frac sR\cos\alpha\big)}\,\mathrm ds$
Now you can use e.g. Wolfram Alpha to integrate this. The result it produced for me was this:
$\int\frac{\sin(\alpha)}{R\,\cos\left(\phi_0+\frac{s\,\cos(\alpha)}{R}\right)}\,\mathrm ds =\\ \tan(\alpha)\left(\log\left(\cos\left(\frac{R\,\phi_0+s\,\cos(\alpha)}{2\,R}\right)+\sin\left(\frac{R\,\phi_0+s\,\cos(\alpha)}{2\,R}\right)\right)\\-\log\left(\cos\left(\frac{R\,\phi_0+s\,\cos(\alpha)}{2\,R}\right)-\sin\left(\frac{R\,\phi_0+s\,\cos(\alpha)}{2\,R}\right)\right)\right)+C$
This is somewhat ugly, but if you take a closer look at the expression, you will notice that the same angle occurs in several places. Let's call this angle
$\beta=\frac{R\,\phi_0+s\,\cos(\alpha)}{2\,R}=\frac{\phi(s)}2$
and you get the expression
$ \tan\alpha\cdot\log\frac{\cos\beta+\sin\beta}{\cos\beta-\sin\beta}+C $
Now you can again ask Wolfram Alpha about this. It doesn't provide a simpler formula, but looking at the plot you might recognize a shifted tangens function. Or you could look at Robert's answer and see that a shifted tangens plays a role there. So you could conjecture
$ \frac{\cos\beta+\sin\beta}{\cos\beta-\sin\beta} = \tan\left(\beta+\frac\pi4\right) $
and use Wolfram Alpha to verify this. So now you know this indefinite integral to be
$\tan\alpha\cdot\log\left(\tan\left(\frac{\phi(s)}{2}+\frac\pi4\right)\right)+C$
With this you have
\begin{align*} \lambda(s) &= \lambda_0 + \tan\alpha\cdot\log\left(\tan\left(\frac{\phi(s)}{2}+\frac\pi4\right)\right) - \tan\alpha\cdot\log\left(\tan\left(\frac{\phi(0)}{2}+\frac\pi4\right)\right) \\ &= \lambda_0 + \tan\alpha\cdot\log\frac{\tan\left(\frac{\phi(s)}{2}+\frac\pi4\right)}{\tan\left(\frac{\phi(0)}{2}+\frac\pi4\right)} \\ &= \lambda_0 + \tan\alpha\cdot\log\frac{\tan\left(\frac{R\,\phi_0 + s\,\cos\alpha}{2\,R}+\frac\pi4\right)}{\tan\left(\frac{\phi_0}{2}+\frac\pi4\right)} \end{align*}
This is the same result Robert Israel gave in his answer, except for the sign of the change. To check that, consider $\alpha=45°$, i.e. you are going northeast. Then your latitude will increase, so the numerator will be greater than the denominator, so the fraction will be greater than one, so the logarithm will be positive, and with $\tan\alpha=1$ you get a positive increase in longitude as well.