Hi You need to look at the head of the phrase for the subject-verb agreement. In this case, you are needing to agree with the number of gallons you need. So you would say - One gallon of paint is all we need.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.