Skip to content

git

GitDirStat – a git maintenance gui

Some time ago I wrote the blog “Remove directories and files permanently from git“. Removing files from a git history is not an unusual task and I thought that it would be nice if there is an easier and faster way to do it. I thought that there should be a gui that help you to find big files in the history and that let you select the files you want to remove with just a click of a button. Therefore I started the GitDirStat project on github and developed a java swing application based on the JGIT library provided by the eclipse community. The name was derived from the popular WinDirStat application or… Read More »GitDirStat – a git maintenance gui

A git checkstyle pre-receive hook

When multiple developers work on one project it is also essential that they all commit source code that matches some formatting rules. Otherwise reviewing changes and merging source code can be a great challenge. When using git repositories you can install hooks. Hooks are any kind of executables that can be run before something happens in a git repository like creating a commit or updating the refs during a push command. I developed a small bash script that can be used to execute checkstyle on every push and that rejects changes that have checkstyle errors. The script is simple and easy to configure so I want to share it here. Just… Read More »A git checkstyle pre-receive hook

How to create an independent branch in git

In a git repository everything normally starts with an initial commit and all other commits are ancestors of this first commit. But is it possible to create a second initial commit or even a third? Another initial commit with a complete different working directory? Yes it is.

Remove directories and files permanently from git

Some day you might want to remove files or directories from git permanently, because someone committed sensitive data or large binary files that should not reside in the repository to keep clone times short.  In this blog I want to show you how to delete directories and files permanently from a git repository. The first chapter is a short answer and is intended for those of you who only want to quickly remove files and don’t want to undestand it in-depth. The section chapter dives into the depth of git and gives you links to other resources to understand how files are managed in git and thus can be removed. The short answer… Read More »Remove directories and files permanently from git

GDPR Cookie Consent with Real Cookie Banner