The caster of a whirlwind spell can use a subsequent action to "move the whirlwind up to 30 feet in any direction along the ground." Is this up 30 feet in a straight line only? Or can the whirlwind move on a curve, or back and forth, potentially increasing the number of creatures that enter its space on this turn?
No, you can move it in any direction
Spells do what they say, and the spell tells you that you can move the whirlwind 30' in any direction; it does not tell you that you have to move it in a straight line, nor that you can move it 30' but only in a single direction. There are no hidden rules. If you can move it so that it can hit more creatures by not following a straight line, you are permitted to do so.
This is also supported by the answer to: When spells can be moved, must it be in a straight line?