Adding some git functions
some problems left

how to handle the repository