Put a tray under it and open and shut it real fast. If water comes out, it's a water line. If you hear hissing and smell rotten eggs, it's a gas line. ¯\_(ツ)_/¯
(Chances are you're not gonna blow yourself up with a fraction of a second's worth of gas leaking out, but for legal reasons this comment is a joke.)