Change mode permission fields to be its own types instead of using Int.

Also provide simple conversion function to extract part of the meaning.
terminate by / some paths.
wrap some reference in a refname and add some validation.

redo listing of valid references.
use the proper name for refname.
add a show-refs subcommands
Merge remote-tracking branch 'nicolas/master'

Conflicts:
	Data/Git/Diff.hs
	Hit/Hit.hs
bump version to 0.5.5