Keep in mind, Rick and his group started the WHOLE thing. Rick tried to strongarm the Hilltop, and then thought he was going to strongarm the Sanctuary. If Rick hadn't been so arrogant, and so eager to prove that he was top dawg, he, in theory could've avoided this situation. Sure, the Saviors are bad, but Rick didn't really know that. He was taking the word of the People at Hilltop, and went on what can only be described as a murderous campaign against them. Shouldve got some intel, shored up defenses at Alexandria, and stayed put.
There is no way they could've avoided conflict with the Saviours. Negan controls the whole area. It was gonna come pretty soon. However, better intel gathering before jumping into action may have given them a better chance of success with less cost. War was coming, no doubt, but our group just hasn't learned how to act proactively yet. They always seem to get into trouble first, then react. They had no clue of the numbers they were going up against.