GithubHelp home page GithubHelp logo

brainless / gitplay Goto Github PK

View Code? Open in Web Editor NEW
20.0 20.0 2.0 6.16 MB

Learn how a software project (using git) evolved over time from its commit log. Its like YouTube for a git project. Desktop app built with Rust and SolidJS

License: MIT License

Rust 29.56% HTML 0.78% CSS 0.52% TypeScript 67.85% JavaScript 1.28%
git gui learn-to-code learning libgit2 software-engineering solidjs tauri

gitplay's People

Contributors

brainless avatar miteshashar avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

gitplay's Issues

API: Get file sizes for list of open files and folders for next X commits

As a GUI developer I need the file sizes for the list of open files and folders to show what changes are happening as we play the repository.

The API request will have a list of all paths that the GUI is tracking (files and folders), starting commit ID and batch size.

The response should contain a list of sizes for each path, keyed by the commit ID when the size changed. Total number of file size changes (keyed by commit ID) will be up to the batch size.

JS Error on hover at beginning of timeline

Following error is thrown when mouse hovers at the beginning point of the timeline:

[Error] Unhandled Promise Rejection: invalid args `startIndex` for command `get_commits`: invalid value: integer `-100`, expected usize

TL;DR

handleTimelineEnter is called for onMouseOver on the timeline bar.
handleTimelineEnter calls loadCommits which in turn invokes a RPC call to get_commits

[Discussion] Group changes into commits and rebase commits to build a better git commit history

This is not directly related to gitplay. But a git feature that would be great, a better devX

Problem statement

We all have worked on a feature intensively and had to refractor a lot of the code base (in early projects). But can't spend the mental expense to context switch from writing code to make meaningful commit messages.

A good commit history is at the expense of the developer, which results in breaking the "flow". As pg mentioned in his blog post Holding a program in one's head, it be better to work in long stretches to have better developer productivity. And it is very common for devs to have to make code cleanups which are unrelated to the feature they are working on (example tweet)

  • Commit small and commit often
  • Writing good git commit messages goes a long way
  • get gud at git

Scenario

Lets say you are building a feature and mid way you came across a variable name that could be fixed. Or a piece of code that is no longer needed. But you don't want to include this unrelated changes in your working commit. So for good practice you need to create a new commit for those changes.

Current solution

  1. git-worktree
    We can currently use git-worktree to create a parellel repo in your local directory and make the changes in that, push a commit, pull the changes in the feature working tree and continue. This is long and hard

  2. stash and make changes
    Make a stash of the current feature changes and then make the required changes, commit and pop the stash. So bad my eyes are bleeding

  3. Make the changes in the current working tree and use git add -p to make patches when creating a commit
    This is what I currently do. But the flaw of this approach is that it looses the essense of story-telling, You may make changes that don't show a history, instead shows a bunch of unrelated changes on top of each other.

The solution

If we could patch changes into commit groups and then finally commit those changes when all the related changes are ready, it will let the developer write code in a long stretch 1 and also build a story for the commit history.

Why commit groups?

We can currently create patches. But using this new feature we can add patches into groups as we read the code to make patches. We will have more than one stages files "area".

Cross posted on hackernews - Link

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.