Fix #3521 version mismatch when running diag, Replaced git command to get current checked out tag