When Adoni-Tzedek king of Yerushalayim heard how Y'hoshua had taken 'Ai and utterly destroyed it - he had done the same to 'Ai and its king as he had done to Yericho and its king - and how the inhabitants of Giv'on had made peace with Isra'el and were living among them,
his people became greatly alarmed; because Giv'on was as large as one of the royal cities, larger than 'Ai, and all its men were courageous.
So Adoni-Tzedek king of Yerushalayim sent this message to Hoham king of Hevron, Pir'am king of Yarmut, Yafia king of Lakhish and D'vir king of 'Eglon:
"Come up and help me, and we'll attack Giv'on, because it has made peace with Y'hoshua and the people of Isra'el."
So the five kings of the Emori - the kings of Yerushalayim, Hevron, Yarmut, Lakhish and 'Eglon - got together, went up with all their armies, pitched camp against Giv'on and made war against it.
The people of Giv'on sent a message to Y'hoshua at their camp in Gilgal that said, "Don't ignore your servants! Come up to us quickly, and save us! Help us, because all the kings of the Emori living in the hills have gotten together to fight us."
Y'hoshua went up from Gilgal, he and all the fighting men with him, including all the bravest ones.
ADONAI said to Y'hoshua, "Don't be afraid of them, for I have handed them over to you; not one of their men will stand against you."
Having spent the entire night marching up from Gilgal, Y'hoshua fell upon them, taking them by surprise.
ADONAI threw them into confusion before Isra'el and defeated them in a great slaughter at Giv'on, pursuing them along the road that goes up from Beit-Horon, and beating them back to 'Azekah and all the way to Makkedah.
As they fled before Isra'el down the road to Beit-Horon, ADONAI threw huge hailstones down on them all the way to 'Azekah, and they died; more died because of the hail than because Isra'el had killed them with the sword.
Then, on the day ADONAI handed over the Emori to the people of Isra'el, Y'hoshua spoke to ADONA I; in the sight of Isra'el he said, "Sun, stand motionless over Giv'on! Moon, you too, over Ayalon Valley!"
So the sun stood still and the moon stayed put, till Isra'el took vengeance on their enemies.
This is written in the book of Yashar. The sun stood still in the sky and was in no rush to set for nearly a whole day. There has never been a day like that before or since, when ADONAI listened to the voice of a man; it happened because ADONAI was fighting on Isra'el's behalf.
Y'hoshua returned with all Isra'el to the camp at Gilgal.
But those five kings fled and hid themselves in the cave at Makkedah,
and it was reported to Y'hoshua that the five kings had been found hiding in the cave at Makkedah.
Y'hoshua said, "Roll big stones to the mouth of the cave, and put men there to guard them.
However, you, don't wait, but keep chasing your enemies, and attack those farthest in the rear. Don't allow them to return to their cities, because ADONAI has handed them over to you."
After Y'hoshua and the people of Isra'el had finished killing them off in a very great slaughter, till they had been destroyed, and the remaining remnant had entered the fortified cities,
all the people returned safely to Y'hoshua at the camp in Makkedah; and no one said a word against any of the people of Isra'el.
Then Y'hoshua said, "Open up the mouth of the cave, and bring those five kings out of the cave to me.
They did it; they brought the five kings out to him - the kings of Yerushalayim, Hevron, Yarmut, Lakhish and 'Eglon.
After they had brought the five kings to Y'hoshua, he summoned all the men of Isra'el and said to the commanders of the soldiers who had gone with him, "Come here and put your feet on the necks of these kings." They came and put their feet on their necks.
Y'hoshua said to them, "Don't be afraid or confused, but be strong and bold, because this is what ADONAI will do to all your enemies that you fight against."
With that, Y'hoshua struck them and put them to death, hanging them on five trees, where they remained hanging until evening.
At sunset Y'hoshua gave an order, and they lowered them from the trees and threw them into the cave where they had hidden themselves, then laid big stones at the mouth of the cave; and there they remain to this day.
Y'hoshua captured Makkedah that day, defeating it and its king by the sword. He completely destroyed them, everyone there - he left no one; and he did to the king of Makkedah what he had done to the king of Yericho.
Y'hoshua went on from Makkedah, and all Isra'el with him, to Livnah; and he fought against Livnah.
ADONAI also handed it and its king over to Isra'el. He defeated it with the sword, everyone there - he left no one, and he did to its king what he had done to the king of Yericho.
Y'hoshua went on from Livnah, and all Isra'el with him, to Lakhish; and he pitched camp against it and fought against it.
ADONAI handed it over to Isra'el; he captured it the second day. He defeated it with the sword, everyone there, exactly as he had done to Livnah.
But then Horam king of Gezer came up to help Lakhish; so Y'hoshua attacked him and his people, until he had no one left with him.
Y'hoshua went on from Lakhish, and all Isra'el with him, to 'Eglon; and he pitched camp against it and fought against it.
They captured it that very day. He defeated it with the sword, completely destroying everyone there, exactly as he had done to Lakhish.
Y'hoshua went up from 'Eglon, and all Isra'el with him, to Hevron; and they fought against it.
They captured it, defeating it with the sword, including its king, its villages and everyone there; he left no one, exactly as he had done to 'Eglon; but he completely destroyed it and everyone there.
Y'hoshua turned back, and all Isra'el with him, to D'vir and fought against it.
They captured it, its king and all its villages, defeating them with the sword and utterly destroying everyone there; he left no one. He did to D'vir and it king as he had done to Hevron and as he had done to Livnah and its king.
So Y'hoshua attacked all the land - the hills, the Negev, the Sh'felah and the mountain slopes - and all their kings; he left none but completely destroyed everything that breathed, as ADONAI the God of Isra'el had ordered.
Y'hoshua attacked them from Kadesh-Barnea to 'Azah and all the land of Goshen, as far as Giv'on.
Y'hoshua captured all these kings and their land all at the same time, because ADONAI the God of Isra'el fought on Isra'el's behalf.
Then Y'hoshua returned, and all Isra'el with him, to the camp at Gilgal.