As KDE is currently migrating from Phabricator to GitLab, it’s a goood time to compare the advantages and disadvantages of both platforms. For phabricator, one of the disadvantages for me is the non-repository-focused structure. For example you can’t easily get to the patches submitted for a project from its repository. The same is valid for the tasks belonging to a project. This makes it harder for new contributors coming from GitHub-like platforms to submit their patches.
GitLab in turn lacks some of the power-user features of Phabricator. One of them is an easy-to-use command line client that does not merely expose the JSON api as shell commands. Since Phabricator has such a client, called arcanist, or in short, arc, which KDE developers and contributors are already used to, I started developing something similar for GitLab.
With it, for example creating a merge request is as easy as running
git lab diff
in a branch containing your commit(s).
To keep track of open merge requests, there is the git lab list
command,
which lists your recently opened merge requests and their status.
For project maintainers, testing merge requests becomes easier as well.
The git lab list --project
command displays merge requests of only the repository the command is run in.
To make testing merge requests locally easier, there is the git lab patch
comand, which checks out a merge request in the local tree.
The tool already supports using multiple GitLab instances, for example invent.kde.org and gitlab.com. Which GitLab instance to use is detected from the repositories origin remote, so there is no need to add something like .arcconfig
files to your repository.
In contrast to arcanist, you don’t need a full PHP runtime, python3 with a small number of packages from pypi is enough.
If you are already convinced, you can install the command using
pip3 install git+https://invent.kde.org/sdk/git-lab
If you have any suggestions on how to do things better or found a bug, feel free to open issues on my repository on invent.kde.org. I especially welcome merge requests. More detailed information can be found in the README of the repository.