Skip to content

bleasey/oak

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OAK: A Version Control System

Oak is a python-based version control system, useful for understanding basic git internals. Our aim is to make a simpler version of Git, one that focuses on local files and repositories. The commands we have defined are similar to Git's in terms of functionality.

Oak Internals

Oak's internal data representation is inspired from Git, but differs in 3 main ways:

  • Git compresses file contents stored before further processing, while Oak doesn't.
  • Git stores metadata such as file creation\modification time, Author name, user ID, hardware device ID, file access permissions, while Oak doesn't.
  • Git stores and manipulates data at the binary bite level, while Oak stores and manipulates data in the usual ASCII form.

We chose to differ from Git it the above ways as Oak is meant to be a demonstrator to basic Git internal principles, so the user can browse through Oak's source code while exploring the .oak folder where data is stored in a readable form. The reason we don't store metadata for now is that Oak was meant to handle local files and repositories, hence the lack of need for storing user and device IDs, file permissions etc.

Oak Functions

We have implemented the following functions as of now:

  • init : initializes an empty repository.
  • commit: commits the files present in the staging area at the time of commit.
  • log: display's commit history and relevant details.
  • short log: similar to log, but display's information in a concise form.
  • add: given files/directories, adds them into the index (staging area).
  • restore: given a filename/directory name, commitID, the function restores the file/directory to its state in the mentioned commit.

Functions yet to be Implemented:

  • reset and revert
  • oakignore
  • diff
  • branch
  • merge

Recommended reading:

About

A python-based version control system, useful for understanding basic git internals.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors