So Joshua took this whole land: the highlands, the whole arid southern plain, the whole land of Goshen, the lowlands, the desert plain, and both the highlands and the lowlands of Israel.
He took land stretching from Mount Halak, which goes up toward Seir, as far as Baal-gad at the foot of Mount Hermon in the Lebanon Valley. He captured all their kings. He struck them down and killed them.
Joshua waged war against all these kings for a long time.
There wasn't one city that made peace with the Israelites, except the Hivites who lived in Gibeon. They captured every single one in battle.
Their stubborn resistance came from the LORD and led them to wage war against Israel. Israel was then able to wipe them out as something reserved for God, without showing them any mercy. This was exactly what the LORD had commanded Moses.
At that time, Joshua went and wiped out the Anakim from the highlands. He wiped them out from Hebron, from Debir, and from Anab, from the whole highlands of Judah, and the whole highlands of Israel. Joshua wiped them out along with their cities as something reserved for God.
The Anakim no longer remained in the land of the Israelites. They survived only in Gaza, Gath, and Ashdod.
So Joshua took the whole land, exactly as the LORD had promised Moses. Joshua gave it as a legacy to Israel according to their tribal shares. Then the land had a rest from war.