I've currently made it work by indexing the ignored file once more. I
used the command:
git update-index --no-assume-unchanged
and then the
checkout command executed easily and properly.
I'll leave this as an answer here. If someone can answer the following
question, I'd be grateful:
Is there some way to checkout the remote branch and then either force
ignoring the file
in my changes or something similar?