Finding the Voltage source function when the function of voltage across inductor is given in SPICE
Firstly, for the given information, there isn't a unique solution.  Recall that:

\$v_L(t) = L \dfrac{di_L(t)}{dt} \$

Thus, when the inductor voltage is zero, the inductor current is constant but, without further information, you don't know the value of this constant current.

Thus, \$v_s\$ is some constant value (the product of the constant inductor current and series resistance) at all times except when \$t=0\$ where it is 1V higher.

Secondly, and AFAIK, in SPICE, one specifies the voltage across a voltage source rather than solving for it.

Thirdly, for the specified inductor voltage, the change in inductor current is non-zero only for an infinitesimal time.  I do not know how one would simulate* this in SPICE which necessarily has finite time steps.

*One could approximate this with a finite though extremely small duration pulse.