https://github.com/ssrathi/golang_git
Implementation of git internals from scratch in Go language
https://github.com/ssrathi/golang_git
git go golang
Last synced: 4 months ago
JSON representation
Implementation of git internals from scratch in Go language
- Host: GitHub
- URL: https://github.com/ssrathi/golang_git
- Owner: ssrathi
- License: mit
- Created: 2020-05-09T03:28:30.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-04-30T18:47:21.000Z (over 3 years ago)
- Last Synced: 2025-07-20T23:18:24.408Z (4 months ago)
- Topics: git, go, golang
- Language: Go
- Homepage:
- Size: 559 KB
- Stars: 49
- Watchers: 2
- Forks: 3
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[](https://github.com/ssrathi/gogit/actions?query=branch%3Amaster+workflow%3ABuild)
[](https://goreportcard.com/report/github.com/ssrathi/gogit)
[](https://godoc.org/github.com/ssrathi/gogit)

# gogit
Implementation of git internal commands in Go language.
This project is part of a learning exercise to implement a subset of "git"
commands. It can be used to create and maintain git objects, such as blobs,
trees, commits, references and tags.
[
](https://asciinema.org/a/331278?speed=2&autoplay=1&t=8)
# Video with explanation
This video is a supplemental tech-talk recording explaining the internals of "git" (Delievered at Nutanix, Inc, 2020)
[
](https://players.brightcove.net/5850956868001/default_default/index.html?videoId=6304540004001)
## Supported commands
```
gogit - the stupid content tracker
usage: gogit []
Valid commands:
init Create an empty Git repository
hash-object Compute object ID and optionally creates a blob from a file
cat-file Provide content or type and size information for repository objects
ls-tree List the contents of a tree object
mktree Build a tree-object from ls-tree formatted text
checkout restore working tree files
commit-tree Create a new commit object
log Shows the commit logs
show-ref List references in a local repository
update-ref Update the object name stored in a ref safely
rev-parse Parse a given git identifier
Use "gogit --help" for help on a specific command
```
## Installation
```
go get github.com/ssrathi/gogit
```
## Contributing
Contributions are most welcome! Please create a new issue and link your PR to it.