Lewis MacLeod hit the winner for Rangers as they enjoyed a 1-0 friendly victory over Bristol City at Ashton Gate on Saturday.