I felt an urge to do something with Scala. Git concepts are complicated, and I used to have issues comprehending them. Git Commands Visualizer is my humblest effort to help close the gap between complex git concepts and understanding them through visualization. This project is powered by scalaJs and slinky for their great integration with the FE ecosystem, allowing writing the UI smoothly. The rest and core logic are vanilla Scala, which handles user inputs, manipulates and maintains various internal tree structures and renders them on screen. It indeed shows what Scala is capable of doing.
Here! Try me
Simply by hitting git commit -m <message> and it will create a commit node for you. You don't have to create anything to make
a successful commit.
- 2021-03-20
- Supported git commands
git branchgit branch
git commitgit commit -m <message>
git checkoutgit checkout <branch>
git mergegit merge <branch or hash>
git pushgit pushgit push origin <head or HEAD>git push origin <branch>
git revertgit revert <commit>
- Supported git commands
- Support cherry-pick command
- UI improvements. Terminal automatically scroll down when user type commands
- The bouncing behaviour of the nodes may seem a bit annoying. There might be room for improvements with no physics and no overlapping.
- The rendering of the git tree is powered by VisJS with a Scala-wrapper that I had implemented. It comes naturally with a physics bouncing behaviour. The nodes allow dragging and resizing.
Simply clone the project and run sbt dev in the terminal. It will be ready on localhost:8080!
The idea of this project is inspired by explain git with d3. The author was once my supervisor, and he is one of the best. :)
