Git Product home page Git Product logo

git-truck's Introduction

Git Truck ๐Ÿš› ยท GitHub license Git Truck on NPM

Git-Truck is a tool that provides you with a truckload of visualizations for your git repository, and helps you find out if your project has a good truck factor.

Git Truck can help you figure out:
Where the files in your codebase that only have a single contributor are (i.e., truck-factor = 1) image
How the various developers contribute to your codebase image
Which parts of the system that are most often changed image

๐Ÿ”’ Private by design

๐Ÿ๏ธ Works offline

๐Ÿคท Git provider agnostic - works with any git repository

๐Ÿ˜Š No tracking, no ads, no data mining, no analytics, no cloud, no servers

Important

To use Git Truck, you will need to have the following programs installed:

  • Node.js 18.0.0 or newer and npm 10.0 or newer
  • git 2.29 or newer

Check your installed versions using node --version, npm --version and git --version.

Tip

The latests versions of Node and git can be installed from the links above.

Note

npm is automatically installed along with node.

  1. Within a git repository, or a directory containing git repositories, run the command
npx -y git-truck
  1. The application will now open in your default browser.

Demo

Please open an issue here where you describe your problem or feature request. For bug reports, please include git version, Node version, npm version, operating system, and an image of the problem would be great too!

If you have any suggestions about new features, or things that you think should be different, also feel free to open an issue.

Run npx git-truck in the root of a git repository, that you want to visualize:

npx git-truck [args]
arg description default value
--path path to a folder or a git repository current directory
--log output log level. See here for values -
--port port to use for the program 3000
--invalidate-cache bypass analyzer cache manually -
--headless run the program without opening the browser -

Caution

Using --invalidate-cache will cause the analyzer to run every time the client talks to the server. This can be very slow if working with large repositories.

You can add a truckconfig.json file to the root of your project, where you can define the arguments you want. Additionally you can define which git-aliases should be considered as the same person using unionedAuthors. If provided, the first name in the array is used as the name of the person. You can also define files to ignore.

Example:

{
  "log":             "debug",
  "branch":          "main",
  "unionedAuthors":  [
    [
      "Bob",
      "Bobby Bob"
    ],
    [
      "Alice",
      "aliiii",
      "alice alice"
    ]
  ],
  "hiddenFiles":     [
    "package-lock.json",
    "*.bin",
    "*.svg"
  ],
  "invalidateCache": true
}

Very large repositories

Tip

If the repository you intend to analyze is very large (300k+ commits), we recommend to increase the memory available to nodejs by setting the environment variable NODE_OPTIONS to --max-old-space-size=4096 before starting Git Truck, otherwise analyzation might crash. If your repository has more than 1 million commits, it is unlikely that Git Truck can successfully analyze it, even with higher memory limit.

Star History

Star History Chart

git-truck's People

Contributors

joglr avatar tjomson avatar emiljapelt avatar hojelse avatar mircealungu avatar actions-user avatar dawidwoz avatar epkanol avatar mimi-shahzad-kt avatar

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.