Recently, when doing a git pull I got the following message:

fatal: refusing to merge unrelated histories

Here’s how I got around that:

On the command line type the following:

git pull --allow-unrelated-histories

By default, git does not allow using unrelated histories due to it causing problems to the history, since a parallel history is created when another developer does a git pull. That is why --allow-unrelated-histories is not turned on by default.