Install git-who on Ubuntu 24.04

Install git-who on Ubuntu 24.04

The git-who is a command line tool that can be used for identifying who is responsible for entire components or subsystems in the repository. It is similar to git blame, but for file trees rather than individual files. This tutorial explains how to install git-who on Ubuntu 24.04.

Prepare environment

Ensure that Git is installed on the system. You can check out a post on how to install it.

Install git-who

Get the latest release version of git-who from its official GitHub repository and save it in a variable:

GIT_WHO_VERSION=$(curl -s "https://api.github.com/repos/sinclairtarget/git-who/releases/latest" | grep -Po '"tag_name": "v\K[0-9.]+')

Download git-who using the version retrieved earlier:

wget -qO git-who.tar.gz https://github.com/sinclairtarget/git-who/releases/latest/download/gitwho_v${GIT_WHO_VERSION}_linux_amd64.tar.gz

Extract the git-who executable to the /usr/local/bin directory:

sudo tar xf git-who.tar.gz --strip-components=1 -C /usr/local/bin linux_amd64/git-who

Check the git-who version as follows:

git who --version

Remove downloaded file:

rm -rf git-who.tar.gz

Testing git-who

Clone the repository and navigate to it:

git clone https://github.com/sinclairtarget/git-who && cd git-who

To see the list of contributors in the repository, run:

git who -l

This command will display a list of contributors along with the number of commits each person has made. Example:

┌──────────────────────────────────────────────────────────────────────────────┐
│Author                          Last Edit   Commits   Files        Lines (+/-)│
├──────────────────────────────────────────────────────────────────────────────┤
│Sinclair Target                 1 day ago       268      62   12,378 /   5,172│
│cono                            17 hr. ago        1       2       52 /       0│
│camerontarget14                 1 day ago         2       1        8 /       2│
└──────────────────────────────────────────────────────────────────────────────┘

Uninstall git-who

To remove git-who, simply delete its executable file:

sudo rm -rf /usr/local/bin/git-who

Leave a Comment

Cancel reply

Your email address will not be published.