In my case, I use a charger that is capable of detecting when the battery has an 80% charge. The other thing I do is to keep my bike indoors so that the battery doesn't get too cold.
That being said, the battery was stolen at one point and was discovered about two years later. During that time it received essentially no maintenance. It still works fine. I use it for daily commuting and charge every couple of days.