No, it is not plausible.
Most bodies in the solar system easily fit into a hundred astronomical unit radius sphere. The nearest star is four light-years away, and a light year is eighty-six thousand astronomical units. The ratio between those distances is 2530[1]. It'd be like hitting a meter size target from more than two and a half kilometer. Pretty good shot, and we're talking about Proxima centaury (which, last time I checked, won't go supernova anytime soon) and the distance between say Sedna and the Sun. If we were talking about an accuracy more of an astronomical unit, more like the distance between Earth and mars, then we're talking about a centimeter sized target.
Thus a gamma-ray burst would have to be insanely narrow to hit Earth and not mars. Not to mention how ridiculously unlucky we would have to be then in order for it to be precisely aimed at us.
1. https://www.wolframalpha.com/input/?i=four+light-year+divide...
It's implausible that one will hit us, but if you're looking for a scientific and logical motivation, it's a possibility.
Also, colonizing mars is a necessary step toward avoiding what happens when our star reaches the end of its life. May as well start while we have the opportunity.