refactor git object, move git_otype to types.jl
hex is a Base function