Gitea – self-hosted Git service

Gitea is yet another alternative to BitBucket, GitHub, and GitLab Cloud.  It’s an open source solution for self-hosting Git repositories.  It’s a fork of Gogs, written in Go, and is available under the MIT license.

git clean – a nice addition to git reset

Anybody working with git is probably well familiar with the way to undo the non-committed changes:

git reset --hard

As useful as the above command is, it still leaves some room for improvement. The above command will only undo non-committed changes on the files that git is tracking. Often, this would leave a whole bunch of files and directories in place, which are not tracked by git. So far, I’ve been using a really complicated approach for removing them, which involves git status, grep, cut, xargs, and rm. Yuck.

Turns out there is a better way, which I found in “Stupid git tricks” article:

git clean -df .

This one will forcefully remove all untracked files and directories from the current directory. Combining these two commands together results in all non-committed changes being undone, no matter if they are on tracked files or not. Cool!

Why SQLite Does Not Use Git

Git is a pretty much standard de facto for version control when it comes to the modern software development.  Yet, there are still many projects, companies, and developers who don’t use it.  Some, like WordPress, for historical reasons – it’ll take a lot of work to migrate all of the infrastructure and community to git.  Others, for personal preference.  An example of the latter is SQLite.

Here’s an interesting article on why SQLite does not use git.  The core reason is simple – the main developer of the SQLite just doesn’t like git, and there is nothing wrong with it.  But in the article there are a few specific technical reasons of why not git, and why Fossil.

Oh sh*t, git!

Oh sh*t, git! is a collection of git problems, their solutions, and some explanations of how that happened and how to get out of it.

Git is hard: screwing up is easy, and figuring out how to fix your mistakes is f*cking impossible. Git documentation has this chicken and egg problem where you can’t search for how to get yourself out of a mess, unless you already know the name of the thing you need to know aboutin order to fix your problem.

GitHub : Quickly review changed functions in your PHP pull requests

GitHub is one of the greatest tools for developers ever.  And it keeps getting better.  Most of the new features that GitHub introduces are usually generic and apply to all developers universally.  Today, however, they have a special present for the PHP developers – Quickly review changed functions in your PHP pull requests.  This is mighty useful, especially on the larger pull requests.