Legalism is not measured by the quantity or quality of laws that one has, but by the attitude of the heart toward the Law, and by the way in which one uses the laws that he has.
One may be every bit as legalistic with one law, or a few, as with a great many rules and regulations.
But one may also have many laws and diligently keep them, and one may even make laws for others to follow, without being at all legalistic about it.
Legalism is a matter of striving to keep the Law, and of requiring others to keep the Law, as though by the Law to redeem and justify oneself. That is a false and misleading dream, we rightly sing. And where that lie prevails, it doesn't matter how many or how few the rules and regulations may be, nor how easy or difficult they are to follow; it is legalistic to insist upon the Law as the way and the means of salvation. Neither does it matter whether one is commanding or forbidding; if it is done as though to accomplish righteousness before God, it is legalistic.
But the Law of God is good and wise, and it is to be used lawfully. It reveals what is the good and acceptable will of God; and in doing that, it exposes sin and actually makes it worse, in order to begin the Lord's good work of repentance in the one He confronts and addresses. Law and order in the world are also among His good gifts of daily bread, for the preservation of human life, and ultimately for the free course of the Gospel and the protection of the Church on earth. Law and order in the Church are also meet, right and salutary, when they are used to serve the Ministry of the Gospel and the common confession of Christ. Here there is not legalism, but its opposite.
It is no more legalistic to say that there is a right and wrong way for the Gospel to be preached and the Sacraments to be administered, than it is to say that Jesus alone is the Way, the Truth and the Life. Nor is it legalistic to say that, for the sake of clarity, consistency and the unity of a common confession, the Church on earth shall conduct herself according to certain standards; even if those standards are neither commanded nor forbidden by God, but are agreed upon in love, in the freedom of the Gospel. It is not legalistic, but precisely evangelical, to insist upon those standards. For the correct response to legalism is not the chaos of anything-goes, but an insistence upon the faithful preaching and administration of the Gospel. Love will require what is good and right on behalf of the neighbor; and love will refuse to allow what is harmful.
The anarchy which says that every man is free to do whatever seems right in his own eyes, is only a more perverse form of legalism. Then redemption and life are located in the self-chosen law of "to thine own self be true," and the solitary self becomes the sole standard and arbiter of righteousness. Better to be driven to do what a Christian ought to do, than to be cut loose from the godly discipline of the Church and left to one's own devices. Thankfully, it doesn't have to be either one of those extremes, but there is a more excellent way. That is to use the Law and all laws lawfully, not for the sake of self-justification, but for the sake of self-sacrificing love; because love, which is the fulfillment of the Law, does no harm to the neighbor but thinks more highly of others than of self. That is not the way of legalism, but of Christ.