git pf

Pull if a merge can be resolved as a fast-forward, otherwise fail

Git alias:

# git pf:
pf = pull --ff-only

Example:

git pf