"In 1780, a majority of Americans were disinclined to support George Washington's Army. Throughout the Revolutionary War, support for the Patriots went up and down, until the victory at Yorktown made the Bruts thrown their hand in. Until Sherman took Atlanta in Septemeber, 1864, public opinion in the north. was willing to make a deal with Jefferson Davis. There is no such thing as a popular war."
I should like to expand on this, because it is directly on the topic I have tried to address.
In the American War of Independence, the Americans were the guerillas. What would have been required for the British to win that war? Depopulation of whole areas in rebellion, killing many, many civilians. The British did win the Boer War, which was an insurgency, and they did it by putting all civilians in concentration camps and killing all civilians who resisted. Insurgencies are wars of populations against armies. The only way to win them is by killing large numbers of people.
In the American Civil War, there were organized armies in the field, but there was also an insurgent population in rebellion supporting them in every way. It was the Union general Sherman's march through Georgia, unleashing the US Army on American citizens, that broke the will of that portion of the South and ended rebellion there. It also intimidated the Carolinas, where Sherman was next headed, into submission, since the choice was to have the civilian population destroyed by the US Army, as had happened in Georgia.
In Algeria, France systematically defeated the FLN insurgents, and in the process inflicted between 100,000 and half a million civilian casualties. President De Gaulle examined well what was required to keep Algerie francaise, and concluded that what would have been required was akin to genocide, a perpetual war against the Arab civilians, driving them into the desert and systematically killing them. De Gaulle concluded that absent that, no victory was possible there. And since De Gaulle was unwilling to commit the French Republic to that course, he decided to withdraw. However, he did not withdraw on his own decision. He presented a referendum to the French people: withdraw from Algeria, or fight to the death. 75% of the French thought that maintaining French control of Algeria was not worth doing to France what would have had to be done to retain it. And so Algeria was let go free.
In the American West, the Americans learnt that the only way to defeat the Indians was to destroy their food supply by killing the buffalo, hound them into reservations, and kill all Indians, men, women or children, who went off the reservation. The Indian reservation was a concentration camp, and it ended successive Indian insurgencies.
In Israel, there is a perpetual insurgency which cannot be defeated. The Israelis have been unwilling to turn the Palestinian areas into concentration camps/Indian reservations and starve those areas still in rebellion into submission. And so the war there continues to percolate, and shall continue to do so.
The only way that insurgencies have ever been defeated in modern history is by concentration camps and unleashing armies on civilian populations. Nothing else has worked, and nothing else is at all likely to work.
This is why, faced with the prospect of an insurgency, a nation has to make a "gut check", to use the American military parlance. If you are NOT willing to resort to concentration camps and unleashing armies on civilians, then entering a war with an insurgency is destined to end in your defeat.
Would the tactics needed to win a war against an insurgency be popular? No. They are brutal. They constitute "crimes against humanity" under international war. The way the British won the Boer War and the Americans won the US Civil War and the Indian Wars all constituted crimes against humanity by present law. But that is how you defeat insurgencies. If you are not willing to commit crimes against humanity, you cannot win such a war and you should not enter into it. It is a matter of doing the "gut check" BEFORE plunging ahead.