Йеошуа 11:20 Галаха: Mishneh Torah, Repentance & Mishneh Torah, Kings and Wars

כִּ֣י מֵאֵ֣ת יְהוָ֣ה ׀ הָיְתָ֡ה לְחַזֵּ֣ק אֶת־לִבָּם֩ לִקְרַ֨את הַמִּלְחָמָ֤ה אֶת־יִשְׂרָאֵל֙ לְמַ֣עַן הַֽחֲרִימָ֔ם לְבִלְתִּ֥י הֱיוֹת־לָהֶ֖ם תְּחִנָּ֑ה כִּ֚י לְמַ֣עַן הַשְׁמִידָ֔ם כַּאֲשֶׁ֛ר צִוָּ֥ה יְהוָ֖ה אֶת־מֹשֶֽׁה׃ (ס)

Ибо от Господа ожесточили их сердца, чтобы они пошли против Израиля в битве, чтобы они могли быть полностью истреблены, чтобы они не имели благосклонности, но чтобы они могли быть уничтожены, как повелел Господь Моисею.

Mishneh Torah, Repentance

And, it is possible that a man should commit either one grievous iniquity or a multitude of sins so that the Judge of Truth will decree against him that, whereas this sinner committed those sins of his own free will and consciously, repentance should be witheld from him altogether, and grant him no leave to repent, so that he might die and perish in the iniquity he committed. Even this is what the Holy One, blessed is He! said through Isaiah: "Make the heart of this people fat, and make their eyes heavy, and shut their eyes; lest they, seeing with their eyes, and hearing with their ears, and understanding with their heart will return and be healed" (Is. 6.10). It is, moreover, said: "But they mocked the messengers of God, and despised His words and scoffed at His prophets, until the wrath of the Lord arose against His people till there was no remedy". (II Chro. 36.16)—as if saying: "They sinned of their own free will and they have multiplied iniquities, until their guilt carried the punishment to withold repentance from them, which is the remedy". It is, therefore, written in the Torah; "And I will harden Pharaoh's heart" (Ex. 14.4), because at the beginning he sinned of his own free will, and meted out evil to Israel who sojourned in his land, even as it is said: "Come, let us deal wisely with them" (Ibid. 1.10). Thereat justice demanded to withold repentance from him, so that due punishment might be visited upon him. Wherefor, the Holy One, blessed is He! hardened his heart. If it be so, then why did He delegate Moses to him, charging him to let Israel go forth and turn to repentance seeing that the Holy One, blessed is He! long since told him thou wilt not let them go forth, saying: "But as for thee and thy servants, I know that ye will not yet fear the Lord God" (Ibid. 9.30), and again saying: "But in very deed for this cause have I made thee to stand, to show thee My power, and that My name be declared throughout all the earth"(Ibid. –16)? To demonstrate to the future generations whenever the Holy One, blessed is He! witholds repentance from a sinner he can not repent, but must die in the original evil which he perpetrated of his own free will. Sihon, too, by the measure of his iniquity became guilty of an offence which carried the punishment to have repentance witheld from him, even as it is said: "For the Lord thy God hardened his spirit, and made his heart obstinate" (Deut. 2.30). Likewise the Canaanites, according to their abominations, did He withold repentance from them so that they engaged Israel in battle, even as it is said: "For it was of the Lord, to harden their hearts, to come against Israel in battle, that they might be utterly destroyed" (Joshua, 11.20). Even so was with Israel in the days of Elijah, because of the multiplied iniquity repentance was witheld from the gross evildoers, for it is said: "For Thou didst turn their heart backward" (I. Kings, 18.37)—as if saying: "Thou didst withold repentance from them". Thus, as a consequence hereof, we must say: God's predestination prompted not Pharaoh to wrong Israel, nor Sihon to sin in his land, nor the Canaanites to be abominable, nor Israel to worship idolatry; for they all sinned of their own free will and accord, and, therefore, were they all guilty of an offence which carries along the punishment to withold repentance from them.

Mishneh Torah, Kings and Wars

If they do not come to peaceful terms or they make peace but do not accept the Seven Commandments, we engage in war against them and slay all their adult males. We take all their money and children as spoils. We do not kill the women or minors, as it says, “the women and the children” (see Deut. 20:14 and 2:34) which means the male children. To what do we refer? To a Discretionary War with one of the other nations. However, with one of the Seven Nations or with Amalek who do not make peace, we leave no soul alive, as it says, “so you shall do with everyone…only of the cities of the nations…do not leave alive any soul” (Deut. 20:15-16), and regarding Amalek it says, “erase the memory of Amalek” (Deut. 25:19). How do we know that this is referring to those who do not make peace with us? For it says, “there was no city which came to peace with the Children of Israel except the Chivites, dwellers of Givon. Everything, they took in the war. For from G-d their hearts were strengthened to the call of war with Israel, so that they may be destroyed.” (Joshua 11:19-20). They were offered peace, and refused.