Path-integral formulation of two-dimensional gauge theories with massless fermions