The potential energy of a uniform sphere of charge $Q$ is:
$$ U_Q = \frac 3 5 \frac 1 {4\pi\epsilon_0} \frac{Q^2}R $$
while the gravitational binding energy is:
$$ U_G = -\frac 3 5 \frac{GM^2} R $$
(Both of these results are standard physics problems).
You want to add them:
$$ U(R) = U_Q(R) + U_G(R) $$
and find the minimum with respect to $R$. Of course, they have the same behavior vs $R$, so that is pointless. One would think it is minimized at $R=\infty$.
However, if you fix $R$, it would be more interesting to the find $Q$ for which:
$$ U_Q = U_G$$
Note that in this treatment, the Sun is approximated as a gas of non interacting Newtonian particles, for which there are only two outcomes: explosion or implosion, depending on the ratio of $Q/M$.
You can use:
$$ -\frac{d(U_Q+U_M)}{dR}$$
to compute the inward or outward pressure.
Without putting in any numbers, if $q_p = 1.000001|e|$, the Sun would be obliterated in fashion that make gamma ray bursts seem dull, as the electric force is $10^{39}$ times stronger than gravity.