This is infeasible for the reason other have mentioned about specific impulse. But surely you can imagine a set of parallel boards with a coil spring between them and a set of cylindrical guide rods to prevent relative rotation between the boards. A motor fixed to one board turns a screw that engages with threaded nut on the other board, mounted on a thrust bearing, and guide bushing that allows a linear movement, but disallows the rotation degree of freedom. Think of the lead screw on a milling machine or lathe.