Remove dependency on head command in Windows