Actually gasoline fumes aren’t all that explosive outside of Hollywood films, and hydrogen isn’t really that dangerous. Less dangerous than many other fuels in fact, since its extreme lightness means that burning hydrogen goes rapidly straight up instead of spreading. As spectacular as the Hindenburg disaster was, 62 out of the 97 onboard survived.
If anything the biggest problem with hydrogen is that it’s hard to contain and hard to condense, so it’s bulky. Hydrogen powered ships are probably the most practical just because bulkiness doesn’t matter that much with them.
As for oil, eventually we’ll stop using just because it’ll run out.