From next time please give specific examples
Hydrogen can be stabilised both by taking away one electron and giving an electron to it. So when it reacts with the metals, it takes one electron from the metals,like NaH and this is not a covalent bond, it is ionic just like NaCl.
Bonds with metals are always ionic and not covalent, because the metals desperatly require electrons of their own to be stable.